diff options
author | friendica <info@friendica.com> | 2012-11-25 23:18:11 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2012-11-25 23:18:11 -0800 |
commit | ccf44f2514856161a1650781b57d90c75e3d110e (patch) | |
tree | 212d4d4da9788a34088c681f111d2b51d74083da | |
parent | cd4e381aa146dd185021c86ac1ecc9755fa81453 (diff) | |
download | volse-hubzilla-ccf44f2514856161a1650781b57d90c75e3d110e.tar.gz volse-hubzilla-ccf44f2514856161a1650781b57d90c75e3d110e.tar.bz2 volse-hubzilla-ccf44f2514856161a1650781b57d90c75e3d110e.zip |
more but slow progress on deliveries. The b*tch is trying to match permissions
-rw-r--r-- | include/zot.php | 34 | ||||
-rw-r--r-- | version.inc | 2 |
2 files changed, 29 insertions, 7 deletions
diff --git a/include/zot.php b/include/zot.php index ba2a6a834..1924f3b23 100644 --- a/include/zot.php +++ b/include/zot.php @@ -614,21 +614,43 @@ function zot_import($arr) { $incoming = $data['pickup']; if(is_array($incoming)) { foreach($incoming as $i) { + + $deliveries = null; + if($i['notify'] && $i['notify']['recipients']) { - // look for our site members in the recipient list - // (fix the notifier to send them...) + $recip_arr = array(); + foreach($i['notify']['recipients'] as $recip) { + $recip_arr[] = array('hash' => base64url_encode(hash('whirlpool',$recip['guid'] . $recip['guid_sig'], true))); + } + stringify_array_elms($recip_arr); + $recips = ids_to_querystr($recip_arr,'hash'); + + $r = q("select * from channel where channel_hash in ( " . $recips . " ) "); + if(! $r) + continue; + + $deliveries = $r; + + // We found somebody on this site that's in the recipient list. + } else { - // look for any site members who are accepting posts from this sender - } - if($i['message'] && $i['message']['type'] === 'activity') { - // process the message + // Public post. look for any site members who are accepting posts from this sender + } + if(! $deliveries) + continue; + if($i['message']) { + if($i['message']['type'] === 'activity') { + // process the message + } + elseif($i['message']['type'] === 'mail') { + } } } } diff --git a/version.inc b/version.inc index a28c146b8..60df03c69 100644 --- a/version.inc +++ b/version.inc @@ -1 +1 @@ -2012-11-19.144 +2012-11-25.150 |