Partially imported data is not removed on error
There are no destroy
method accepting only a userId
in the models but when there is an error during the CozyDB migration we call the destroy
method of each model with the userId
only:
https://framagit.org/kresusapp/kresus/blob/master/server/models/index.js#L135
Edited by Nicolas Frandeboeuf