From 094a0f438885633e75f98136bd3d0752533407bd Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Fri, 16 Jun 2023 13:02:47 -0600 Subject: [PATCH] Only set the device_vendor when the value is not empty --- app/extensions/extension_edit.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/extensions/extension_edit.php b/app/extensions/extension_edit.php index bd7b42fa35..3c7c887110 100644 --- a/app/extensions/extension_edit.php +++ b/app/extensions/extension_edit.php @@ -533,7 +533,7 @@ } else { //use the mac address to get the vendor - $device_vendor = device::get_vendor($device_mac_address); + $device_vendor = device::get_vendor($device_mac_address); } //determine the name @@ -599,7 +599,9 @@ $array["devices"][$j]["domain_uuid"] = $_SESSION['domain_uuid']; $array["devices"][$j]["device_mac_address"] = $device_mac_address; $array["devices"][$j]["device_label"] = $extension; - $array["devices"][$j]["device_vendor"] = $device_vendor; + if (!empty($device_vendor)) { + $array["devices"][$j]["device_vendor"] = $device_vendor; + } if (!empty($device_templates[$d])) { $array["devices"][$j]["device_template"] = $device_templates[$d]; }