lib/locomotive/middlewares/base.rb
# Create a 301 response and set it up accordingly.
#
# @params [ String ] url The url for the redirection
#
# @return [ Array ] It has the 3 parameters (status, header, body)
#
Create a 301 response and set it up accordingly.
Create a 301 response and set it up accordingly .
def redirect_to(url)
        response = Rack::Response.new
        response.redirect(url, 301) 
        response.finish
        response.to_a
      end
def redirect_to ( url ) response = Rack :: Response . new response . redirect ( url , 301 ) response . finish response . to_a end
Create a 301 response and set it up accordingly.
Create a 301 response and set it up accordingly .
# moved permanently
It has the 3 parameters (status, header, body)
It has the 3 parameters ( status header body )
 Array 
url
<not_specific>
params
[ String ] url The url for the redirection
[ String ] url The url for the redirection