From cf83985a3cd5367063d1c6dda529dbc664d66b6a Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Sun, 18 Jan 2015 21:20:28 +0100 Subject: [PATCH] Fix checking peer role --- vroom.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vroom.pl b/vroom.pl index 64049a2..b8b32eb 100755 --- a/vroom.pl +++ b/vroom.pl @@ -1448,7 +1448,7 @@ any '/api' => sub { my $peer_id = $req->{param}->{peer_id}; if ($self->session($room->{name}) && $self->session($room->{name})->{role}){ # If we just have been promoted to owner - if ($self->session($room)->{role} ne 'owner' && + if ($self->session($room->{name})->{role} ne 'owner' && $self->get_peer_role({room => $room->{name}, peer_id => $peer_id}) eq 'owner'){ $self->session($room)->{role} = 'owner'; $self->associate_key_to_room(