From 669863843bf430bb88d68d00d51500d93465608a Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Wed, 15 Jul 2015 08:30:09 +0200 Subject: [PATCH] Remove uninitialized warning --- vroom.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vroom.pl b/vroom.pl index 5829607..5630864 100755 --- a/vroom.pl +++ b/vroom.pl @@ -2231,7 +2231,8 @@ group { # TODO: support several auth method, including an internal one where user are managed # in our DB, and another where auth is handled by the web server $self->login; - if ($self->get_key_role($self->session('key'), undef) ne 'admin'){ + my $role = $self->get_key_role($self->session('key'), undef); + if (!$role || $role ne 'admin'){ $self->make_key_admin($self->session('key')); } $self->purge_rooms;