From f84151e1fe830dca59ae83de429670dfde76b7d2 Mon Sep 17 00:00:00 2001 From: redmatrix Date: Tue, 22 Sep 2015 04:24:54 -0700 Subject: fix foreach warning --- include/zot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/zot.php b/include/zot.php index fb55da0fa..d0f4f5680 100644 --- a/include/zot.php +++ b/include/zot.php @@ -957,7 +957,7 @@ function zot_process_response($hub, $arr, $outq) { logger('zot_process_response: headers: ' . print_r($arr['header'],true), LOGGER_DATA); } - if(array_key_exists('delivery_report',$x)) { + if(array_key_exists('delivery_report',$x) && is_array($x['delivery_report'])) { foreach($x['delivery_report'] as $xx) { if(is_array($xx) && array_key_exists('message_id',$xx)) { q("insert into dreport ( dreport_mid, dreport_site, dreport_recip, dreport_result, dreport_time, dreport_xchan ) values ( '%s', '%s','%s','%s','%s','%s' ) ", -- cgit v1.2.3