mardi 27 novembre 2018, 18:26:35 CET Dan Book wrote:
> You can make the check_credentials a method of that controller rather than
> a function and call it as $self->check_credentials. Or if you need it
> outside of that controller you can even make it a helper method.

Slightly off-topic: I suggest you to use
Mojolicious::Plugin::Authentication[1] that will handle sessions for
you and give you some helpers like is_user_authenticated,
current_user, etc.

[1] https://metacpan.org/pod/Mojolicious::Plugin::Authentication
-- 
Luc
https://fiat-tux.fr/
https://luc.frama.io/
Internet n'est pas compliqué, Internet est ce que vous en faites.



-- 
You received this message because you are subscribed to the Google Groups 
"Mojolicious" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/mojolicious.
For more options, visit https://groups.google.com/d/optout.

Reply via email to