From 0dc7ceea3f7437baa36f09cdfcb33d18a1398119 Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Mon, 13 Jul 2015 23:59:23 +0200 Subject: [PATCH] Remove some debuging lines --- vroom.pl | 9 --------- 1 file changed, 9 deletions(-) diff --git a/vroom.pl b/vroom.pl index b5ff80f..975abd8 100755 --- a/vroom.pl +++ b/vroom.pl @@ -1043,21 +1043,17 @@ helper key_can_do_this => sub { } my $role = $self->get_key_role($data->{token}, $data->{param}->{room}); if (!$role){ - $self->app->log->debug("Key " . $data->{token} . " has no role in room " . $data->{param}->{room}); return 0; } # API key is an admin one ? if ($role eq 'admin'){ - $self->app->log->debug("Admin API Key, every actions are allowed"); return 1; } # Global actions can only be performed by admin keys if (!$data->{param}->{room}){ - $self->app->log->debug("Invalid room ID"); return 0; } - $self->app->log->debug("Key role: " . $role . " and action: " . $data->{action}); # If this key has owner privileges on this room, allow both owner and partitipant actions if ($role eq 'owner' && ($actions->{owner}->{$data->{action}} || $actions->{participant}->{$data->{action}})){ return 1; @@ -1066,11 +1062,6 @@ helper key_can_do_this => sub { elsif ($role eq 'participant' && $actions->{participant}->{$data->{action}}){ return 1; } - # Else, deny - $self->log_event({ - event => 'action_denied', - msg => "API Key " . $data->{token} . " doesn't have permission to call " . $data->{action} . " on room " . $data->{param}->{room} - }); return 0; };