Ver código fonte

Removed right-stripping and addition of '/' from ExtendedURLValidator because it doesn't work with URLs that have query strings.

master
AndrewIngram 14 anos atrás
pai
commit
a7ec5825c4
1 arquivos alterados com 1 adições e 1 exclusões
  1. 1
    1
      oscar/core/validators.py

+ 1
- 1
oscar/core/validators.py Ver arquivo

@@ -32,5 +32,5 @@ class ExtendedURLValidator(validators.URLValidator):
32 32
         Puts preceding and trailing slashes to local URL name
33 33
         """
34 34
         if value != '/':
35
-            value = '/' + value.strip('/') + '/'
35
+            value = '/' + value.lstrip('/')
36 36
         return value

Carregando…
Cancelar
Salvar