From 0b1cd826b05b6ec9637e373735967a2555eeb1d4 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Tue, 29 Sep 2015 11:48:41 +0200 Subject: do not store a recalled mail if we can not find the original mid --- include/items.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include') diff --git a/include/items.php b/include/items.php index 7793d1fb2..ccc327409 100755 --- a/include/items.php +++ b/include/items.php @@ -3522,11 +3522,17 @@ function mail_store($arr) { dbesc($arr['mid']), intval($arr['channel_id']) ); + if($r) { logger('mail_store: duplicate item ignored. ' . print_r($arr,true)); return 0; } + if(! $r && $arr['mail_recalled'] = 1) { + logger('mail_store: recalled item not found. ' . print_r($arr,true)); + return 0; + } + call_hooks('post_mail',$arr); if(x($arr,'cancel')) { -- cgit v1.2.3 From 2a2da48d1871f408232a8397632f06528c8b43ae Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Tue, 29 Sep 2015 11:56:43 +0200 Subject: fix typo in 0b1cd826b05b6ec9637e373735967a2555eeb1d4 --- include/items.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/items.php b/include/items.php index ccc327409..e7cc02579 100755 --- a/include/items.php +++ b/include/items.php @@ -3528,7 +3528,7 @@ function mail_store($arr) { return 0; } - if(! $r && $arr['mail_recalled'] = 1) { + if(! $r && $arr['mail_recalled'] == 1) { logger('mail_store: recalled item not found. ' . print_r($arr,true)); return 0; } -- cgit v1.2.3