Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[FIXED JENKINS-17317] ”My Views" links leads to 404 Not Found.
- Loading branch information
Showing
with
5 additions
and 2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -145,7 +145,7 @@ public View getPrimaryView() { | ||
} | ||
|
||
public HttpResponse doIndex() { | ||
return new HttpRedirect("view/" + Util.encode(getPrimaryView().getViewName()) + "/"); | ||
This comment has been minimized.
This comment has been minimized.
ssogabe
Author
Member
|
||
} | ||
|
||
public synchronized void doCreateView(StaplerRequest req, StaplerResponse rsp) | ||
@@ -262,5 +262,5 @@ public String getUrlName() { | ||
} | ||
|
||
} | ||
|
||
} |
What exactly does this accomplish?
encode
is not suitable for creating URLs as it does not escape general characters, only space (U+0020) and non-ASCII (U+0080–U+FFFF).encodeRFC2396
would probably do what you want (it is deprecated for no clear reason), as wouldrawEncode
(I think).