mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-04 02:43:48 +00:00
Account for a gateway uuid which in a rare edge case the UUID is upper case
This commit is contained in:
@@ -74,7 +74,12 @@ else {
|
||||
function switch_gateway_status($gateway_uuid, $result_type = 'xml') {
|
||||
$fp = event_socket_create($_SESSION['event_socket_ip_address'], $_SESSION['event_socket_port'], $_SESSION['event_socket_password']);
|
||||
$cmd = 'api sofia xmlstatus gateway '.$gateway_uuid;
|
||||
return trim(event_socket_request($fp, $cmd));
|
||||
$response = trim(event_socket_request($fp, $cmd));
|
||||
if ($response == "Invalid Gateway!") {
|
||||
$cmd = 'api sofia xmlstatus gateway '.strtoupper($gateway_uuid);
|
||||
$response = trim(event_socket_request($fp, $cmd));
|
||||
}
|
||||
return $response;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user