From cad40846066c1dfb99a1ec5c587111f72abd1595 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Mon, 17 Jul 2006 20:16:07 +0000 Subject: [PATCH] Added a parameter in API->delete() to optionally stop the running of API->set_existing() [api.php] --- api.php | 9 +++++++-- dev/changes.txt | 1 + 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/api.php b/api.php index 4dbbf1f..68eb613 100644 --- a/api.php +++ b/api.php @@ -484,15 +484,20 @@ class API * Deletes a record * * @access public + * + * @param bool Run API->set_existing()? */ - function delete() + function delete($runset = true) { if ($this->condition == '') { trigger_error('Condition is empty: cannot fetch', E_USER_ERROR); } - $this->set_existing(); + if ($runset) + { + $this->set_existing(); + } $this->run_action_method('pre_delete'); diff --git a/dev/changes.txt b/dev/changes.txt index 33a7c81..e5a92c0 100644 --- a/dev/changes.txt +++ b/dev/changes.txt @@ -5,6 +5,7 @@ - DB_MySQL can now properly escape binary - No longer populate API->values[] when calling API->fetch() [api.php] - Added a parameter in Mail->send() to optionally clear the to list after sending [mail.php] +- Added a parameter in API->delete() to optionally stop the running of API->set_existing() [api.php] 2.0.0 =============== -- 2.43.5