Update provision.php
This commit is contained in:
parent
b92eb051bb
commit
c7e8f39783
|
|
@ -176,16 +176,6 @@ include "root.php";
|
||||||
return $mac;
|
return $mac;
|
||||||
}
|
}
|
||||||
|
|
||||||
//define a function to check if a contact exists in the contacts array
|
|
||||||
private function contact_exists($contacts, $uuid) {
|
|
||||||
if (is_array($contacts[$uuid])) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//send http error
|
//send http error
|
||||||
private function http_error($error) {
|
private function http_error($error) {
|
||||||
if ($error === "404") {
|
if ($error === "404") {
|
||||||
|
|
@ -201,6 +191,16 @@ include "root.php";
|
||||||
exit();
|
exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//define a function to check if a contact exists in the contacts array
|
||||||
|
private function contact_exists($contacts, $uuid) {
|
||||||
|
if (is_array($contacts[$uuid])) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private function contact_append(&$contacts, &$line, $domain_uuid, $device_user_uuid, $is_group){
|
private function contact_append(&$contacts, &$line, $domain_uuid, $device_user_uuid, $is_group){
|
||||||
$sql = "select c.contact_uuid, c.contact_organization, c.contact_name_given, c.contact_name_family, ";
|
$sql = "select c.contact_uuid, c.contact_organization, c.contact_name_given, c.contact_name_family, ";
|
||||||
$sql .= "c.contact_type, c.contact_category, p.phone_label,";
|
$sql .= "c.contact_type, c.contact_category, p.phone_label,";
|
||||||
|
|
@ -529,7 +529,9 @@ include "root.php";
|
||||||
if ($_SESSION['provision']['debug']['boolean'] == 'true'){
|
if ($_SESSION['provision']['debug']['boolean'] == 'true'){
|
||||||
echo "<br/>device disabled<br/>";
|
echo "<br/>device disabled<br/>";
|
||||||
}
|
}
|
||||||
$this->http_error('404');
|
else {
|
||||||
|
$this->http_error('404');
|
||||||
|
}
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue