aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAndrew Manning <tamanning@zoho.com>2016-06-15 21:48:47 -0400
committerAndrew Manning <tamanning@zoho.com>2016-06-15 21:48:47 -0400
commitfc7c4e64ff71bfccdbad763ee60096e3d262d277 (patch)
tree69f5ed162b0a848b2f3a08316323d78d1b935479 /include
parent688171d016412f30a3ed60d4dc70feb64a19621b (diff)
parent476116a972c0f8b8ade495de557b8fc8d3097964 (diff)
downloadvolse-hubzilla-fc7c4e64ff71bfccdbad763ee60096e3d262d277.tar.gz
volse-hubzilla-fc7c4e64ff71bfccdbad763ee60096e3d262d277.tar.bz2
volse-hubzilla-fc7c4e64ff71bfccdbad763ee60096e3d262d277.zip
Merge remote-tracking branch 'upstream/dev' into wiki
Diffstat (limited to 'include')
-rw-r--r--include/follow.php2
-rw-r--r--include/zot.php10
2 files changed, 11 insertions, 1 deletions
diff --git a/include/follow.php b/include/follow.php
index 0c3973175..e5a74f85e 100644
--- a/include/follow.php
+++ b/include/follow.php
@@ -275,7 +275,7 @@ function new_contact($uid,$url,$channel,$interactive = false, $confirm = false)
call_hooks('follow', $arr);
- /** If there is a default group for this channel, add this member to it */
+ /** If there is a default group for this channel, add this connection to it */
if($default_group) {
require_once('include/group.php');
diff --git a/include/zot.php b/include/zot.php
index af79b5723..043139e2f 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -538,6 +538,16 @@ function zot_refresh($them, $channel = null, $force = false) {
Zotlabs\Daemon\Master::Summon(array('Onepoll',$new_connection[0]['abook_id']));
}
+
+ /** If there is a default group for this channel, add this connection to it */
+ $default_group = $channel['channel_default_group'];
+ if($default_group) {
+ require_once('include/group.php');
+ $g = group_rec_byhash($channel['channel_id'],$default_group);
+ if($g)
+ group_add_member($channel['channel_id'],'',$x['hash'],$g['id']);
+ }
+
unset($new_connection[0]['abook_id']);
unset($new_connection[0]['abook_account']);
unset($new_connection[0]['abook_channel']);