diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2022-11-09 08:24:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-09 08:24:21 +0100 |
commit | e98833748e80275a88560155a0b912667dd2d70b (patch) | |
tree | ec0d8f68e810e95784efb98e1f603bc86cc247cf /app/workers/verify_account_links_worker.rb | |
parent | 53817294fc95eabfed6129138f9aaa920e13c4b9 (diff) |
Fix being able to spoof link verification (#20217)
- Change verification to happen in `default` queue
- Change verification worker to only be queued if there's something to do
- Add `link` tags from metadata fields to page header of profiles
Diffstat (limited to 'app/workers/verify_account_links_worker.rb')
-rw-r--r-- | app/workers/verify_account_links_worker.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/app/workers/verify_account_links_worker.rb b/app/workers/verify_account_links_worker.rb index 8114d59bea3..f606e6c26fe 100644 --- a/app/workers/verify_account_links_worker.rb +++ b/app/workers/verify_account_links_worker.rb @@ -3,14 +3,13 @@ class VerifyAccountLinksWorker include Sidekiq::Worker - sidekiq_options queue: 'pull', retry: false, lock: :until_executed + sidekiq_options queue: 'default', retry: false, lock: :until_executed def perform(account_id) account = Account.find(account_id) account.fields.each do |field| - next unless !field.verified? && field.verifiable? - VerifyLinkService.new.call(field) + VerifyLinkService.new.call(field) if field.requires_verification? end account.save! if account.changed? |