Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add profile_updated_at to clear cache key (#1795)
  • Loading branch information
Zhao-Andy authored and maestromac committed Feb 14, 2019
1 parent 0ddf4a8 commit 84fbbed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/services/moderator/banisher.rb
Expand Up @@ -22,7 +22,7 @@ def reassign_and_bust_username
new_name = "spam_#{rand(10000)}"
new_username = "spam_#{rand(10000)}"
end
user.update_columns(name: new_name, username: new_username, old_username: user.username)
user.update_columns(name: new_name, username: new_username, old_username: user.username, profile_updated_at: Time.current)
CacheBuster.new.bust("/#{user.old_username}")
end

Expand Down

0 comments on commit 84fbbed

Please sign in to comment.