If I update it as follows:
model = ModelClass.create(id: 1, foo: 'bar')
model.updateAttribute('id', '123')
I have 2 instances of this object:
// in chrome console
>ModelClass.records
Object {1: ModelClass, 123: ModelClass}
How can I update model id without duplication of models?
P.S. To synchronize with the server I'm using web sockets. I need to update the temporary id to the real