From e631410a14d68c6c54242cf833c0de9c79bc09dd Mon Sep 17 00:00:00 2001 From: tbrehm Date: Wed, 21 Jul 2010 15:41:48 +0000 Subject: [PATCH] Fixed: FS#1220 - /var/vmail/(domain)/(user) directories and files not delete when mail_user is deleted via remote. --- interface/lib/classes/remoting.inc.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/interface/lib/classes/remoting.inc.php b/interface/lib/classes/remoting.inc.php index 6c08b51a3..6ae0d163d 100644 --- a/interface/lib/classes/remoting.inc.php +++ b/interface/lib/classes/remoting.inc.php @@ -2065,6 +2065,13 @@ class remoting { //* Load the form definition $app->remoting_lib->loadFormDef($formdef_file); + $old_rec = $app->remoting_lib->getDataRecord($primary_id); + + // set a few values for compatibility with tform actions, mostly used by plugins + $this->oldDataRecord = $old_rec; + $this->id = $primary_id; + $this->dataRecord = $params; + //* Get the SQL query $sql = $app->remoting_lib->getDeleteSQL($primary_id); @@ -2079,8 +2086,7 @@ class remoting { //* Save changes to Datalog if($app->remoting_lib->formDef["db_history"] == 'yes') { - $rec = $app->remoting_lib->getDataRecord($primary_id); - $app->remoting_lib->datalogSave('DELETE',$primary_id,$rec,array()); + $app->remoting_lib->datalogSave('DELETE',$primary_id,$old_rec,array()); } -- GitLab