diff --git a/app/destinations/destination_delete.php b/app/destinations/destination_delete.php index b402e68a6d..db81db1fde 100644 --- a/app/destinations/destination_delete.php +++ b/app/destinations/destination_delete.php @@ -62,6 +62,9 @@ else { } unset ($prep_statement); +//start the atomic transaction + $db->beginTransaction(); + //delete the dialplan if (isset($dialplan_uuid)) { $sql = "delete from v_dialplan_details "; @@ -84,6 +87,9 @@ else { $db->exec(check_sql($sql)); unset($sql); +//commit the atomic transaction + $db->commit(); + //synchronize the xml config save_dialplan_xml();