Skip to content

Commit

Permalink
allow access to voyager's Expert mode with QueryString
Browse files Browse the repository at this point in the history
  • Loading branch information
sdumetz committed Dec 13, 2024
1 parent 3371640 commit 8bb7dc3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/server/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ export default async function createServer(config = defaultConfig) :Promise<expr

app.get("/ui/scenes/:scene/edit", canWrite, (req, res)=>{
let {scene} = req.params;
let {lang} = req.query;
let {mode="Edit"} = req.query;
let host = getHost(req);
let referrer = new URL(req.get("Referrer")||`/ui/scenes/`, host);
let thumb = new URL(`/scenes/${encodeURIComponent(scene)}/scene-image-thumb.jpg`, host);
Expand All @@ -180,7 +180,7 @@ export default async function createServer(config = defaultConfig) :Promise<expr
scene,
thumb: thumb.toString(),
referrer: referrer.toString(),
mode: "Edit",
mode,
});
});

Expand Down

0 comments on commit 8bb7dc3

Please sign in to comment.