aboutsummaryrefslogtreecommitdiffstats
path: root/include/notifier.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-08-23 19:42:45 -0700
committerFriendika <info@friendika.com>2011-08-23 19:42:45 -0700
commitb57a01dc1418cc179ddd327af9d04a9e68e679e9 (patch)
tree74034b098c767efa5431e5d9585a76818595c5d0 /include/notifier.php
parent838d89a1104eae279fd80d337ce322560f0bda97 (diff)
downloadvolse-hubzilla-b57a01dc1418cc179ddd327af9d04a9e68e679e9.tar.gz
volse-hubzilla-b57a01dc1418cc179ddd327af9d04a9e68e679e9.tar.bz2
volse-hubzilla-b57a01dc1418cc179ddd327af9d04a9e68e679e9.zip
that was ugly - let's do better
Diffstat (limited to 'include/notifier.php')
-rw-r--r--include/notifier.php17
1 files changed, 9 insertions, 8 deletions
diff --git a/include/notifier.php b/include/notifier.php
index 47dccc1bd..1c8245c7a 100644
--- a/include/notifier.php
+++ b/include/notifier.php
@@ -619,17 +619,18 @@ function notifier_run($argv, $argc){
);
if(count($n)) {
- switch($n[0]['network']) {
+ $contact = $n[0];
+ switch($contact['network']) {
case NETWORK_DFRN :
- logger('notifier: dfrnpubdelivery: ' . $n[0]['name']);
- $deliver_status = dfrn_deliver($owner,$n[0],$atom);
+ logger('notifier: dfrnpubdelivery: ' . $contact['name']);
+ $deliver_status = dfrn_deliver($owner,$contact,$atom);
break;
case NETWORK_DIASPORA :
require_once('include/diaspora.php');
if(get_config('system','dfrn_only') || (! get_config('system','diaspora_enabled')) || (! $normal_mode))
break;
- if(! $n[0]['pubkey'])
+ if(! $contact['pubkey'])
break;
if($target_item['verb'] === ACTIVITY_DISLIKE) {
@@ -638,21 +639,21 @@ function notifier_run($argv, $argc){
}
elseif(($target_item['deleted']) && ($target_item['verb'] !== ACTIVITY_LIKE)) {
// diaspora delete,
- diaspora_send_retraction($target_item,$owner,$n[0]);
+ diaspora_send_retraction($target_item,$owner,$contact);
break;
}
elseif($followup) {
// send comments, likes and retractions of likes to owner to relay
- diaspora_send_followup($target_item,$owner,$n[0]);
+ diaspora_send_followup($target_item,$owner,$contact);
break;
}
elseif($target_item['parent'] != $target_item['id']) {
// we are the relay - send comments, likes and unlikes to our conversants
- diaspora_send_relay($target_item,$owner,$n[0]);
+ diaspora_send_relay($target_item,$owner,$contact);
break;
}
elseif($top_level) {
- diaspora_send_status($target_item,$owner,$n[0]);
+ diaspora_send_status($target_item,$owner,$contact);
break;
}
default: