Skip to content
Browse files

fall back to REQUEST_URI if SCRIPT_URI is not provided

  • Loading branch information...
1 parent 005a711 commit 2225b53274f8f7d1976b56b99ad0c80d106dad55 @oetiker committed May 18, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 software/backend/lib/EP.pm
View
2 software/backend/lib/EP.pm
@@ -89,7 +89,7 @@ sub startup {
$self->hook( before_dispatch => sub {
my $self = shift;
- my $uri = $self->req->env->{SCRIPT_URI};
+ my $uri = $self->req->env->{SCRIPT_URI} || $self->req->env->{REQUEST_URI};
my $path_info = $self->req->env->{PATH_INFO};
$uri =~ s|/?${path_info}$|/| if $path_info and $uri;
$self->req->url->base(Mojo::URL->new($uri)) if $uri;

0 comments on commit 2225b53

Please sign in to comment.
Something went wrong with that request. Please try again.