summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-06-27 02:48:50 +0200
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-06-27 10:42:10 +0200
commitd7e049d5e833cebb0a67c771943d33c532f8923a (patch)
tree35933351eb3966d3cbb017f40d43139a953c99ce
parent3a67b8f28728d3071c9a64d9b8c07ab91919676f (diff)
router: Fix usage of globs2023-06-deps-update
warning: doing a prefix match with globs is deprecated, invalid segment "pleroma*path". You can either replace by a single segment match: /foo/bar-:var Or by mixing single segment match with globs: /foo/bar-:var/*rest
-rw-r--r--lib/pleroma/web/router.ex4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pleroma/web/router.ex b/lib/pleroma/web/router.ex
index c1a690e28..6b9e158a3 100644
--- a/lib/pleroma/web/router.ex
+++ b/lib/pleroma/web/router.ex
@@ -996,8 +996,8 @@ defmodule Pleroma.Web.Router do
scope "/", Pleroma.Web.Fallback do
get("/registration/:token", RedirectController, :registration_page)
get("/:maybe_nickname_or_id", RedirectController, :redirector_with_meta)
- match(:*, "/api/pleroma*path", LegacyPleromaApiRerouterPlug, [])
- get("/api*path", RedirectController, :api_not_implemented)
+ match(:*, "/api/pleroma/*path", LegacyPleromaApiRerouterPlug, [])
+ get("/api/*path", RedirectController, :api_not_implemented)
get("/*path", RedirectController, :redirector_with_preload)
options("/*path", RedirectController, :empty)