Use current_user to avoid looking up the user again via the reaction (#4592)
This commit is contained in:
parent
b70186af0b
commit
7943aa0280
1 changed files with 1 additions and 1 deletions
|
|
@ -49,7 +49,7 @@ class ReactionsController < ApplicationController
|
|||
category: category,
|
||||
).first
|
||||
if reaction
|
||||
reaction.user.touch
|
||||
current_user.touch
|
||||
reaction.destroy
|
||||
Notification.send_reaction_notification_without_delay(reaction, reaction.reactable.user)
|
||||
Notification.send_reaction_notification_without_delay(reaction, reaction.reactable.organization) if organization_article?(reaction)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue