From 62c7d6a4c4a25961a303db08ba7a875a068047fb Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Sun, 10 Aug 2025 01:44:38 -0600 Subject: [PATCH] Correct the original data array The original data array old_array, the value should be null for adding records with an insert --- resources/classes/database.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/classes/database.php b/resources/classes/database.php index be4b655f45..f405013d81 100644 --- a/resources/classes/database.php +++ b/resources/classes/database.php @@ -2326,7 +2326,7 @@ if (permission_exists(self::singular($parent_name).'_add')) { //add to the old and new arrays - $old_array[$parent_name][] = null; + $old_array = null; $new_array[$parent_name][] = $parent_field_array; //prepare the insert statement @@ -2882,7 +2882,7 @@ } //add to the old and new arrays - $old_array[$child_name][] = null; + $old_array = null; $new_array[$child_name][] = $row; //build the insert