As of now, the `userId` of an answer can not be modified due to the following PG trigger: https://github.com/orbiting/backends/blob/d3907139f210774b6720d0f68a22ab46bb09df02/packages/voting/migrations/sqls/20190907043631-questionnaire-improvements-up.sql#L20-L26 A possible workarround could be this: https://github.com/orbiting/backends/commit/0ad0aca9e714c5c213694a426429d68baeafc199 As of now, I am not certain if this PG trigger is important, and if the above code change would break something. Additionally, mergeUsers() might fail due to unic constraints. We need to figure out a good way to automatically merge such users.
As of now, the
userIdof an answer can not be modified due to the following PG trigger:backends/packages/voting/migrations/sqls/20190907043631-questionnaire-improvements-up.sql
Lines 20 to 26 in d390713
A possible workarround could be this: 0ad0aca
As of now, I am not certain if this PG trigger is important, and if the above code change would break something.
Additionally, mergeUsers() might fail due to unic constraints. We need to figure out a good way to automatically merge such users.