DEV: Use strings for :user_email job type argument

Job arguments go via JSON, and so symbols will appear as strings in the Job's `#execute` method. The latest version of Sidekiq has started warning about this to reduce developer confusion.
This commit is contained in:
David Taylor
2022-02-04 17:34:38 +00:00
parent 3a85c4d680
commit c3a54eb30f
6 changed files with 8 additions and 8 deletions

View File

@ -24,7 +24,7 @@ class EmailUpdater
if existing_user = User.find_by_email(email)
if SiteSetting.hide_email_address_taken
Jobs.enqueue(:critical_user_email, type: :account_exists, user_id: existing_user.id)
Jobs.enqueue(:critical_user_email, type: "account_exists", user_id: existing_user.id)
else
error_message = +'change_email.error'
error_message << '_staged' if existing_user.staged?