mirror of
https://github.com/dani/vroom.git
synced 2024-06-01 21:11:41 +02:00
Simplify login
This commit is contained in:
parent
42a8962fdd
commit
8c2267abec
4
vroom.pl
4
vroom.pl
|
@ -118,7 +118,7 @@ helper login => sub {
|
|||
my $self = shift;
|
||||
my $ret = {};
|
||||
if ($self->session('name')){
|
||||
return {ok => 1};
|
||||
return 1;
|
||||
}
|
||||
my $login = $ENV{'REMOTE_USER'} || lc $self->get_random(256);
|
||||
$self->session(
|
||||
|
@ -126,7 +126,7 @@ helper login => sub {
|
|||
ip => $self->tx->remote_address
|
||||
);
|
||||
$self->app->log->info($self->session('name') . " logged in from " . $self->tx->remote_address);
|
||||
return {ok => 1};
|
||||
return 1;
|
||||
};
|
||||
|
||||
# Expire the cookie
|
||||
|
|
Loading…
Reference in New Issue
Block a user