Skip to content

Commit ccf0f97

Browse files
committed
Check if exception causes the spec to fail.
1 parent 0f42c10 commit ccf0f97

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

notifications/lib/notifications/slack_notifier.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def notify_about_timer_reset(event)
5353
game = ReadModel::GameReadModel.find_by(id: event.data[:game_id])
5454
return unless game && game.slack_token
5555
player_id = game.registered_slots&.dig(event.data[:slot])
56-
player = Player.find(player_id) if player_id
56+
player = Player.find_by(id: player_id) if player_id
5757
CustomSlackClient.post_message(
5858
channel: game.slack_channel,
5959
text: game.build_slack_timer_reset_message(event.data, player),

0 commit comments

Comments
 (0)