voltrb / volt

A Ruby web framework where your Ruby runs on both server and client
MIT License
3.22k stars 196 forks source link

bug in Volt::Errors (e.g. when buffer.save! causes duplicate key error) #325

Open balmoral opened 8 years ago

balmoral commented 8 years ago

To replicate the issue create a buffer on an existing model instance and save it (without modification).

For example:

store._items.first.buffer.save!

This should cause a duplicate key error on item.id, but processing of the error in Volt::Errors#merge! fails on line 14

messages.each do |message|

because messages s a String.

balmoral commented 8 years ago

see pull request for potential fix