Fix a problem with canonical requests and the path detection.