From fd4bcd9f09305c057e91a4f791c74d00da9ac143 Mon Sep 17 00:00:00 2001
From: Wouter D'Haeseleer <wouter.dhaeseleer@vasco.com>
Date: Fri, 4 Jan 2013 15:05:00 +0100
Subject: [PATCH] Fixing request.fullpath URL encoding

Let's assume your path is = "project/tree/master/This%20Is%20valid"
In this case gitlab renders a 404.

To fix this we should decode the path so that it looks like
"project/tree/master/This Is valid"
---
 lib/extracts_path.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/extracts_path.rb b/lib/extracts_path.rb
index 0b7a0d47ca..d1e569ce3e 100644
--- a/lib/extracts_path.rb
+++ b/lib/extracts_path.rb
@@ -108,7 +108,7 @@ module ExtractsPath
       request.format = :atom
     end
 
-    path = request.fullpath.dup
+    path = CGI::unescape(request.fullpath.dup)
 
     @ref, @path = extract_ref(path)
 
-- 
2.30.9