From 65c937a91ae4fbce979c7f027b785ebfc5a8c370 Mon Sep 17 00:00:00 2001 From: Matthew Landauer Date: Tue, 1 Oct 2024 06:29:53 +0000 Subject: [PATCH] Remove unnecessary code --- app/controllers/alerts_controller.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/controllers/alerts_controller.rb b/app/controllers/alerts_controller.rb index 3e73254ed..df615621f 100644 --- a/app/controllers/alerts_controller.rb +++ b/app/controllers/alerts_controller.rb @@ -48,8 +48,6 @@ def create redirect_to alerts_path, notice: "You succesfully added a new alert for #{alert.address}" else @alert = T.let(alert, T.nilable(Alert)) - # TODO: Is there a more sensible way of doing this? - @alerts = T.let(policy_scope(Alert), T.nilable(ActiveRecord::Relation)) render :new end end @@ -117,8 +115,6 @@ def user_session redirect_to alerts_path, notice: "You succesfully added a new alert for #{alert.address}" else @alert = T.let(alert, T.nilable(Alert)) - # TODO: Is there a more sensible way of doing this? - @alerts = T.let(policy_scope(Alert), T.nilable(ActiveRecord::Relation)) render :new end