1
This commit is contained in:
Evan Pratten 2023-03-27 14:45:11 -04:00
parent 8d49aca7f3
commit 7cc5234741

View File

@ -16,12 +16,11 @@ export function onRequest(context) {
// The first segment of the path is probably the user
var path_split = url.pathname.split("/");
return new Response(path_split);
// The image name is the part between `/vx/` and the first action token
var image_name = "";
for (var token of path_split) {
if (token == "v2") {
if (token == "v2" || token == "") {
continue;
}
if (POSSIBLE_ACTION_TOKENS.includes(token)) {