multiple "under sub{}" in Mojolicious::Lite? #2289
hadjiprocopis
started this conversation in
General
Replies: 1 comment 3 replies
-
|
In Mojolicious::Lite, this is what 'group' is for, to allow you to construct this into a tree as routes in Mojolicious::Lite are all top level by default: https://metacpan.org/pod/Mojolicious::Guides::Tutorial#Under |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Perhaps my design is wrong but I need to have certain routes going
under2 routes, one after the other.For example route A is for doing a login/authorisation, and route B is for doing some query after authorised.
Both routes A and B must check if a 3rd party server is up and running before continuing. So they must both be
underroute CheckServer.Route B must additionally be under an "Auth" route, i.e. if the user has a auth cookie.
So I went about with this:
But it seems to be that the second
underoverwrites the first one.Beta Was this translation helpful? Give feedback.
All reactions