Projet

Général

Profil

« Précédent | Suivant » 

Révision 7f9ff0b2

Ajouté par Frédéric Péters il y a environ 4 ans

  • ID 7f9ff0b2c974619dbe9237443276fc2c0aa2c1e1
  • Parent 191b1d46

misc: don't reencode REQUEST_URI from uwsgi (#40073)

Voir les différences:

auquotidien/modules/root.py
272 272
                if not uri_rest:
273 273
                    # REQUEST_URI doesn't exist when using internal HTTP server
274 274
                    # (--http)
275
                    uri_rest = get_request().get_path()
275
                    uri_rest = urllib.parse.quote(get_request().get_path())
276 276
                    if get_request().get_query():
277 277
                        uri_rest += '?' + get_request().get_query()
278 278
                if uri_rest.startswith(base_url):
......
280 280
                if f.category:
281 281
                    if f.category.url_name == f.url_name:
282 282
                        return FormsRootDirectory(f.category)._q_traverse(path[1:])
283
                    scheme, netloc, path, params, query, fragment = urllib.parse.urlparse(uri_rest)
284
                    path = urllib.parse.quote(path)
285
                    uri_rest = urllib.parse.urlunparse((scheme, netloc, path, params, query, fragment))
286 283
                    return redirect('%s%s/%s' % (base_url, f.category.url_name, uri_rest))
287 284

  
288 285
            try:

Formats disponibles : Unified diff