summaryrefslogtreecommitdiffstats
path: root/lib/private/AppFramework
diff options
context:
space:
mode:
authorb108@volgograd <b108@volgograd>2019-01-20 13:29:58 +0400
committerb108@volgograd <b108@volgograd>2019-01-20 13:29:58 +0400
commitbf167ad3acb2be4083cd96d58bf13fba83ad9e39 (patch)
treecb52facae39e1a85f2bf51ed11bfcaa075bc4fdc /lib/private/AppFramework
parentf12b589d40048109ca38c3c6426d1c9d23f05e65 (diff)
downloadnextcloud-server-bf167ad3acb2be4083cd96d58bf13fba83ad9e39.tar.gz
nextcloud-server-bf167ad3acb2be4083cd96d58bf13fba83ad9e39.zip
Remove duplicate functionality
This functionality implemented in the next line: $requestUri = preg_replace('%/{2,}%', '/', $requestUri);
Diffstat (limited to 'lib/private/AppFramework')
-rw-r--r--lib/private/AppFramework/Http/Request.php6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/private/AppFramework/Http/Request.php b/lib/private/AppFramework/Http/Request.php
index 00668e87e34..c205cc5f81b 100644
--- a/lib/private/AppFramework/Http/Request.php
+++ b/lib/private/AppFramework/Http/Request.php
@@ -759,11 +759,7 @@ class Request implements \ArrayAccess, \Countable, IRequest {
*/
public function getRawPathInfo(): string {
$requestUri = isset($this->server['REQUEST_URI']) ? $this->server['REQUEST_URI'] : '';
- // remove too many leading slashes - can be caused by reverse proxy configuration
- if (strpos($requestUri, '/') === 0) {
- $requestUri = '/' . ltrim($requestUri, '/');
- }
-
+ // remove too many slashes - can be caused by reverse proxy configuration
$requestUri = preg_replace('%/{2,}%', '/', $requestUri);
// Remove the query string from REQUEST_URI