Clone objects before saving in case of a retry
authorTom Hughes <tom@compton.nu>
Mon, 28 Nov 2016 20:31:04 +0000 (20:31 +0000)
committerTom Hughes <tom@compton.nu>
Mon, 28 Nov 2016 20:31:04 +0000 (20:31 +0000)
commite5834016fd30a975d162478469d030fc168d98fe
tree840f7500e0f47bb95acec45d5aa859acc82b5391
parentebf443d22d267edfdba0b16b850f698b61895e01
Clone objects before saving in case of a retry

If a deadlock occurs then the transaction will be retried so we
need to make sure that the object will still be dirty so that it
will be saved again during the retry but that the version won't
be incremented a second time.
app/models/node.rb
app/models/relation.rb
app/models/way.rb