Skip to content

Commit

Permalink
Issue #3261858 by DamienMcKenna, heddn: The path of a URI with an aut…
Browse files Browse the repository at this point in the history
…hority must start with a slash "/" or be empty. Automagically fixing the URI. (#164)

Co-authored-by: Lucas Hedding <[email protected]>
  • Loading branch information
kporras07 and Lucas Hedding authored Feb 14, 2023
1 parent cf53b51 commit 8ec16ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Services/PantheonGuzzle.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ public function requestUriAlterForPantheonEnvironment(RequestInterface $request)
$path_parts = array_filter($path_parts, function ($item) {
return !empty($item);
});
$uri = $uri->withPath(implode('/', $path_parts));
$uri = $uri->withPath('/' . ltrim(implode('/', $path_parts), '/'));
return $request->withUri($uri);
}

Expand Down

0 comments on commit 8ec16ff

Please sign in to comment.