TT#116900 Use multidomain when deleting a registration

* deleting a registration would fail when the domain
            of the registrations would not exist due to the
            fact that multidomain is not enabled

Change-Id: If512c0c9ce6c8f7a72deaa5b6a8ebe6737404f2a
(cherry picked from commit a9817e52d8)
mr9.2
Flaviu Mates 4 years ago
parent f9d5f7b2b6
commit c95b2189ca

@ -4353,7 +4353,7 @@ sub delete_registered :Chained('registered') :PathPart('delete') :Args(0) {
try {
my $reg = $c->stash->{registered} // die "No registration data";
my $aor = $reg->username . '@' . $reg->domain;
my $aor = $reg->username . ($c->config->{features}->{multidomain} ? '@' . $reg->domain : '');
NGCP::Panel::Utils::Kamailio::delete_location_contact($c, $aor, $reg->contact);
} catch($e) {
NGCP::Panel::Utils::Message::error(

Loading…
Cancel
Save