mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-09-18 11:04:33 +08:00
[SCI-5635] Use update_column in the migration in order to avoid callbacks
This commit is contained in:
parent
b6a4a5326f
commit
4c29de62be
1 changed files with 2 additions and 2 deletions
|
@ -24,9 +24,9 @@ class FixLastChangedByOnSteps < ActiveRecord::Migration[6.1]
|
|||
.order(created_at: :desc)
|
||||
.first
|
||||
if activity && user_id = activity.values.dig('message_items', 'user', 'id')
|
||||
step.update!(last_modified_by_id: user_id)
|
||||
step.update_column(:last_modified_by_id, user_id)
|
||||
else
|
||||
step.update!(last_modified_by_id: step.user_id)
|
||||
step.update_column(:last_modified_by_id, step.user_id)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue