mirror of
https://github.com/dani/vroom.git
synced 2024-06-26 17:43:29 +02:00
Rename get_notification to get_email_notifications
This commit is contained in:
parent
7c42333af4
commit
8826076e0a
8
vroom.pl
8
vroom.pl
|
@ -555,7 +555,7 @@ helper update_email_notifications => sub {
|
||||||
};
|
};
|
||||||
|
|
||||||
# Return the list of email addresses
|
# Return the list of email addresses
|
||||||
helper get_notification => sub {
|
helper get_email_notifications => sub {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
my ($room) = @_;
|
my ($room) = @_;
|
||||||
$room = $self->get_room_by_name($room) || return undef;
|
$room = $self->get_room_by_name($room) || return undef;
|
||||||
|
@ -1760,7 +1760,7 @@ any '/api' => sub {
|
||||||
ask_for_name => ($room->{ask_for_name}) ? 'yes' : 'no',
|
ask_for_name => ($room->{ask_for_name}) ? 'yes' : 'no',
|
||||||
persistent => ($room->{persistent}) ? 'yes' : 'no',
|
persistent => ($room->{persistent}) ? 'yes' : 'no',
|
||||||
max_members => $room->{max_members},
|
max_members => $room->{max_members},
|
||||||
notif => $self->get_notification($room->{name}),
|
notif => $self->get_email_notifications($room->{name}),
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -1802,7 +1802,7 @@ any '/api' => sub {
|
||||||
locked => ($room->{locked}) ? 'yes' : 'no',
|
locked => ($room->{locked}) ? 'yes' : 'no',
|
||||||
ask_for_name => ($room->{ask_for_name}) ? 'yes' : 'no',
|
ask_for_name => ($room->{ask_for_name}) ? 'yes' : 'no',
|
||||||
max_members => $room->{max_members},
|
max_members => $room->{max_members},
|
||||||
notif => $self->get_notification($room->{name}),
|
notif => $self->get_email_notifications($room->{name}),
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -1839,7 +1839,7 @@ any '/api' => sub {
|
||||||
my $name = $req->{param}->{name} || '';
|
my $name = $req->{param}->{name} || '';
|
||||||
my $subj = sprintf($self->l('s_JOINED_ROOM_s'), ($name eq '') ? $self->l('SOMEONE') : $name, $room->{name});
|
my $subj = sprintf($self->l('s_JOINED_ROOM_s'), ($name eq '') ? $self->l('SOMEONE') : $name, $room->{name});
|
||||||
# Send notifications
|
# Send notifications
|
||||||
my $recipients = $self->get_notification($room->{name});
|
my $recipients = $self->get_email_notifications($room->{name});
|
||||||
foreach my $rcpt (keys %{$recipients}){
|
foreach my $rcpt (keys %{$recipients}){
|
||||||
$self->app->log->debug('Sending an email to ' . $recipients->{$rcpt}->{email});
|
$self->app->log->debug('Sending an email to ' . $recipients->{$rcpt}->{email});
|
||||||
my $sent = $self->mail(
|
my $sent = $self->mail(
|
||||||
|
|
Loading…
Reference in New Issue
Block a user