Skip to content

Commit 7f9ad55

Browse files
committed
Change option delimiter from + to :
- This avoids potential issue from filename of `+` which are typically valid, while `:` may be invalid as a filename and thus problems with disambiguating it are avoided, as `%2B` are normalized to `+`, while `%3A` does not get normalized and thus disambiguation is possible in the off chance someone does create a file named `:`.
1 parent 8774c5d commit 7f9ad55

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

pmrapp/src/exposure.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ pub fn ExposureRoutes() -> impl MatchNestedRoutes + Clone {
109109
<ParentRoute path=ParamSegment("id") view=Exposure>
110110
<Route path=StaticSegment("/") view=ExposureMain/>
111111
<Route path=StaticSegment("") view=RedirectTS/>
112-
<Route path=(StaticSegment("+"), StaticSegment("wizard")) view=Wizard/>
112+
<Route path=(StaticSegment(":"), StaticSegment("wizard")) view=Wizard/>
113113
<Route path=WildcardSegment("path") view=ExposureFile/>
114114
</ParentRoute>
115115
</ParentRoute>
@@ -300,7 +300,7 @@ pub fn Exposure() -> impl IntoView {
300300
req_action: None,
301301
},
302302
ContentActionItem {
303-
href: format!("{resource}+/wizard"),
303+
href: format!("{resource}:/wizard"),
304304
text: "Wizard".to_string(),
305305
title: Some("Build this exposure".to_string()),
306306
req_action: Some("edit".to_string()),

pmrapp/src/main.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ async fn main() -> anyhow::Result<()> {
117117

118118
// build our application with a route
119119
let app = Router::new()
120+
.without_v07_checks()
120121
.route("/workspace/{workspace_id}/rawfile/{commit_id}/{*path}", get(raw_workspace_download))
121122
.route(WIZARD_FIELD_ROUTE, post(wizard_field_update))
122123
.leptos_routes(

pmrapp/src/workspace.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ pub fn WorkspaceRoutes() -> impl MatchNestedRoutes + Clone {
6363
<ParentRoute path=StaticSegment("/workspace") view=WorkspaceRoot ssr>
6464
<Route path=StaticSegment("/") view=WorkspaceListing/>
6565
<Route path=StaticSegment("") view=RedirectTS/>
66-
<Route path=(StaticSegment("+"), StaticSegment("add")) view=WorkspaceAdd/>
66+
<Route path=(StaticSegment(":"), StaticSegment("add")) view=WorkspaceAdd/>
6767
<ParentRoute path=ParamSegment("id") view=Workspace>
6868
<Route path=StaticSegment("/") view=WorkspaceMain/>
6969
<Route path=StaticSegment("") view=RedirectTS/>
@@ -124,7 +124,7 @@ fn workspace_root_page_ctx() -> impl IntoView {
124124
async move {
125125
Some(vec![
126126
ContentActionItem {
127-
href: format!("/workspace/+/add"),
127+
href: format!("/workspace/:/add"),
128128
text: "Add Workspace".to_string(),
129129
title: Some("Add a new workspace".to_string()),
130130
req_action: Some("create".to_string()),

0 commit comments

Comments
 (0)