Skip to content
Snippets Groups Projects
Unverified Commit d83d01eb authored by Matt Jankowski's avatar Matt Jankowski Committed by GitHub
Browse files

Fix `Lint/RedundantSafeNavigation` cop (#28172)

parent a98fccf8
No related branches found
No related tags found
No related merge requests found
......@@ -49,7 +49,7 @@ class Api::V1::AccountsController < Api::BaseController
end
def mute
MuteService.new.call(current_user.account, @account, notifications: truthy_param?(:notifications), duration: (params[:duration]&.to_i || 0))
MuteService.new.call(current_user.account, @account, notifications: truthy_param?(:notifications), duration: params[:duration].to_i)
render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships
end
......
......@@ -37,7 +37,7 @@ class Trends::History
end
def uses
with_redis { |redis| redis.get(key_for(:uses))&.to_i || 0 }
with_redis { |redis| redis.get(key_for(:uses)).to_i }
end
def add(account_id)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment