mirror of
https://github.com/discourse/discourse.git
synced 2025-06-04 23:36:11 +08:00
DEV: remove update_attributes which is deprecated in Rails 6
See: https://github.com/rails/rails/pull/31998 update_attributes is a relic of the past, it should no longer be used.
This commit is contained in:
@ -45,7 +45,7 @@ class BadgesController < ApplicationController
|
||||
if current_user
|
||||
user_badge = UserBadge.find_by(user_id: current_user.id, badge_id: @badge.id)
|
||||
if user_badge && user_badge.notification
|
||||
user_badge.notification.update_attributes read: true
|
||||
user_badge.notification.update read: true
|
||||
end
|
||||
if user_badge
|
||||
@badge.has_badge = true
|
||||
|
Reference in New Issue
Block a user