Skip to content

Commit

Permalink
add another possible prefix for extension admin api route
Browse files Browse the repository at this point in the history
  • Loading branch information
mathieuancelin committed Jan 23, 2025
1 parent f060bf6 commit 488fcea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion otoroshi/app/next/extensions/extension.scala
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ class AdminExtensions(env: Env, _extensions: Seq[AdminExtension]) {
Some(ApiAction.async { ctx => route.adminRoute.handle(route, ctx.request, ctx.apiKey, None) })
case None => f
}
} else if (hasExtensions && request.path.startsWith("/api/extensions/") && adminApiRoutes.nonEmpty) {
} else if (hasExtensions && (request.path.startsWith("/api/extensions/") || request.path.startsWith("/apis/extensions/")) && adminApiRoutes.nonEmpty) {
adminApiRouter.find(request) match {
case Some(route) if route.adminRoute.wantsBody =>
Some(ApiAction.async(sourceBodyParser) { ctx =>
Expand Down

0 comments on commit 488fcea

Please sign in to comment.