From 0167bb0a513683962117e1fed2ad9bb3a2db6925 Mon Sep 17 00:00:00 2001 From: swaggboi Date: Wed, 5 Jan 2022 21:44:58 -0500 Subject: [PATCH] Create /reset route to start a new session --- www-swagg.pl | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/www-swagg.pl b/www-swagg.pl index 8f0a097..f61677f 100755 --- a/www-swagg.pl +++ b/www-swagg.pl @@ -101,6 +101,14 @@ get '/ula6', sub { $c->render(ula6 => $ula6); }; +# Reset session cookie +get '/reset', sub { + my ($c) = @_; + + $c->session(expires => 1); + $c->redirect_to('index'); +}; + # Default route get '/:route', [route => [qw{die me news portal}]], sub { my ($c) = @_;