Permalink
Browse files

Add sub replacement for double-slash on request.fullpath when Spree i…

…s mounted at root
  • Loading branch information...
1 parent 765db7c commit c6fb95602387e142658223d075099611d153ac63 @ethier ethier committed with radar Jun 1, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 core/lib/spree/core/ssl_requirement.rb
@@ -102,10 +102,10 @@ def ssl_supported?
def ensure_proper_protocol
return true if ssl_allowed?
if ssl_required? && !request.ssl? && ssl_supported?
- redirect_to "https://" + request.host + request.fullpath
+ redirect_to "https://" + request.host + request.fullpath.sub("//", "/")
flash.keep
elsif request.ssl? && !ssl_required?
- redirect_to "http://" + request.host + request.fullpath
+ redirect_to "http://" + request.host + request.fullpath.sub("//", "/")
flash.keep
end

0 comments on commit c6fb956

Please sign in to comment.