When I get a request for a path that includes the word \'self\' I want to replace it with the user id before matching it to a URL. I tried using a middleware like this:
Apparently, the URL marching is not done using request.path but request.path_info. The same middleware altering this variable works.
request.path
request.path_info