Don't try to log token if it's not defined

master
Daniel Berteaud 10 years ago
parent 188d333098
commit 89a5e5bbc4
  1. 2
      vroom.pl

@ -694,12 +694,12 @@ helper check_invite_token => sub {
my ($room,$token) = @_; my ($room,$token) = @_;
# Expire invitations before checking if it's valid # Expire invitations before checking if it's valid
$self->purge_invitations; $self->purge_invitations;
$self->app->log->debug("Checking if invitation with token $token is valid for room $room");
my $ret = 0; my $ret = 0;
my $data = $self->get_room_by_name($room); my $data = $self->get_room_by_name($room);
if (!$data || !$token){ if (!$data || !$token){
return 0; return 0;
} }
$self->app->log->debug("Checking if invitation with token $token is valid for room $room");
my $sth = eval { my $sth = eval {
$self->db->prepare('SELECT COUNT(`id`) $self->db->prepare('SELECT COUNT(`id`)
FROM `email_invitations` FROM `email_invitations`

Loading…
Cancel
Save