From fbb784c2f5ca1fc5bd88d5e44aa8ad5d34e0679e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20Nicolaysen=20S=C3=B8rnes?= Date: Tue, 17 Apr 2007 23:28:10 +0000 Subject: [PATCH] Fix mails for updated test results. Pass the correct 'edit' parameter to sendNotificationMail() and only send mail if the test data has been changed. --- include/testData.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/include/testData.php b/include/testData.php index 993ee0c..b63968e 100644 --- a/include/testData.php +++ b/include/testData.php @@ -100,6 +100,11 @@ class testData{ return; } + $oOldTest = new testData($this->iTestingId); + /* Nothing changed */ + if($this == $oOldTest) + return TRUE; + if(query_parameters("UPDATE testResults SET versionId = '?', whatWorks = '?', @@ -127,7 +132,7 @@ class testData{ $this->iTestingId)) { if(!$bSilent) - $this->SendNotificationMail(); + $this->SendNotificationMail("edit"); return true; } else