Skip to content

Commit ad4d2d2

Browse files
committed
Fix rubocop offences
1 parent 4d08141 commit ad4d2d2

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

actionpack/test/controller/redirect_test.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -204,11 +204,9 @@ def redirect_with_null_bytes
204204
end
205205

206206
def redirect_to_external_with_rescue
207-
begin
208-
redirect_to "http://www.rubyonrails.org/", allow_other_host: false
209-
rescue ActionController::Redirecting::UnsafeRedirectError
210-
render plain: "caught error"
211-
end
207+
redirect_to "http://www.rubyonrails.org/", allow_other_host: false
208+
rescue ActionController::Redirecting::UnsafeRedirectError
209+
render plain: "caught error"
212210
end
213211

214212
def rescue_errors(e) raise e end

0 commit comments

Comments
 (0)