Permalink
Browse files

Added Request#ssl? which is shorthand for @request.protocol == "https…

…://"

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
dhh committed Nov 24, 2004
1 parent e0b904e commit 1042de2370354ddb283eaa2a6c3a6166f7aaf0be
Showing with 6 additions and 0 deletions.
  1. +2 −0 actionpack/CHANGELOG
  2. +4 −0 actionpack/lib/action_controller/request.rb
View
@@ -1,5 +1,7 @@
*CVS*
* Added Request#ssl? which is shorthand for @request.protocol == "https://"
* Added the choice to call form_tag with no arguments (resulting in a form posting to current action) [bitsweat]
* Upgraded to Builder 1.2.1
@@ -54,6 +54,10 @@ def protocol
port == 443 ? "https://" : "http://"
end
def ssl?
protocol == "https://"
end
def path
request_uri ? request_uri.split("?").first : ""
end

0 comments on commit 1042de2

Please sign in to comment.