diff --git a/actionpack/lib/abstract_controller/url_for.rb b/actionpack/lib/abstract_controller/url_for.rb index 5f22b4525150c1091ea98606c270c1e690285426..72d07b09270294e43ee12ddf087c7af8c12ce2c9 100644 --- a/actionpack/lib/abstract_controller/url_for.rb +++ b/actionpack/lib/abstract_controller/url_for.rb @@ -10,7 +10,7 @@ module UrlFor include ActionDispatch::Routing::UrlFor def _routes - raise "In order to use #url_for, you must include routing helpers explicitly.\n" \ + raise "In order to use #url_for, you must include routing helpers explicitly. " \ "For instance, `include Rails.application.routes.url_helpers`." end diff --git a/actionpack/lib/action_dispatch/http/mime_negotiation.rb b/actionpack/lib/action_dispatch/http/mime_negotiation.rb index 7a99bc235c5ed2db4fcc924cc4daf789fc5283bb..cab60a508a62dc07ceda3d3d1d1c470dbbc302c4 100644 --- a/actionpack/lib/action_dispatch/http/mime_negotiation.rb +++ b/actionpack/lib/action_dispatch/http/mime_negotiation.rb @@ -81,9 +81,9 @@ def variant=(variant) if variant.all? { |v| v.is_a?(Symbol) } @variant = ActiveSupport::ArrayInquirer.new(variant) else - raise ArgumentError, "request.variant must be set to a Symbol or an Array of Symbols.\n" \ - "For security reasons, never directly set the variant to a user-provided value,\n" \ - "like params[:variant].to_sym. Check user-provided value against a whitelist first,\n" \ + raise ArgumentError, "request.variant must be set to a Symbol or an Array of Symbols. " \ + "For security reasons, never directly set the variant to a user-provided value, " \ + "like params[:variant].to_sym. Check user-provided value against a whitelist first, " \ "then set the variant: request.variant = :tablet if params[:variant] == 'tablet'" end end