Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15336418
D19190.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D19190.diff
View Options
diff --git a/src/applications/diffusion/controller/DiffusionController.php b/src/applications/diffusion/controller/DiffusionController.php
--- a/src/applications/diffusion/controller/DiffusionController.php
+++ b/src/applications/diffusion/controller/DiffusionController.php
@@ -69,13 +69,18 @@
// repository has a different canonical path like "/diffusion/XYZ/...",
// redirect them to the canonical path.
- $request_path = $request->getPath();
- $repository = $drequest->getRepository();
+ // Skip this redirect if the request is an AJAX request, like the requests
+ // that Owners makes to complete and validate paths.
+
+ if (!$request->isAjax()) {
+ $request_path = $request->getPath();
+ $repository = $drequest->getRepository();
- $canonical_path = $repository->getCanonicalPath($request_path);
- if ($canonical_path !== null) {
- if ($canonical_path != $request_path) {
- return id(new AphrontRedirectResponse())->setURI($canonical_path);
+ $canonical_path = $repository->getCanonicalPath($request_path);
+ if ($canonical_path !== null) {
+ if ($canonical_path != $request_path) {
+ return id(new AphrontRedirectResponse())->setURI($canonical_path);
+ }
}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Mar 9, 6:48 PM (1 w, 6 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7385772
Default Alt Text
D19190.diff (1 KB)
Attached To
Mode
D19190: Fix broken suggestion/validation for Owners paths in repositories with short names
Attached
Detach File
Event Timeline
Log In to Comment