From ba3f721524bb3cfdc37142d5069268e91d960cb2 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sun, 22 Apr 2018 04:46:46 -0400 Subject: [PATCH] Prevent side effect with cascade => false in dba::delete --- include/dba.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/dba.php b/include/dba.php index 3209021cf2..b41a7aab76 100644 --- a/include/dba.php +++ b/include/dba.php @@ -894,7 +894,7 @@ class dba { } // Is there a relation entry for the table? - if (isset(self::$relation[$table])) { + if ($cascade && isset(self::$relation[$table])) { // We only allow a simple "one field" relation. $field = array_keys(self::$relation[$table])[0]; $rel_def = array_values(self::$relation[$table])[0]; -- 2.39.5