aboutsummaryrefslogtreecommitdiffstats
path: root/include/zot.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/zot.php')
-rw-r--r--include/zot.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/include/zot.php b/include/zot.php
index c4860cc3b..1c6a09494 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -1092,9 +1092,15 @@ function zot_import($arr, $sender_url) {
$recip_arr[] = make_xchan_hash($recip['guid'],$recip['guid_sig']);
}
}
- stringify_array_elms($recip_arr);
- $recips = implode(',',$recip_arr);
- $r = q("select channel_hash as hash from channel where channel_hash in ( " . $recips . " ) and channel_removed = 0 ");
+
+ $r = false;
+ if($recip_arr) {
+ stringify_array_elms($recip_arr);
+ $recips = implode(',',$recip_arr);
+ $r = q("select channel_hash as hash from channel where channel_hash in ( " . $recips . " )
+ and channel_removed = 0 ");
+ }
+
if(! $r) {
logger('recips: no recipients on this site');
continue;