aboutsummaryrefslogtreecommitdiffstats
path: root/mod/magic.php
diff options
context:
space:
mode:
authormrjive <mrjive@mrjive.it>2016-01-28 23:19:13 +0100
committermrjive <mrjive@mrjive.it>2016-01-28 23:19:13 +0100
commit28943af494eae225b256b9771a5699a1b05d7a2f (patch)
tree1f135da64c0935053f468281f8353e8279a18448 /mod/magic.php
parentc49e4f52ae83441c4a1dcf52e433dded8d767679 (diff)
parent5f1eb18da4d6380b64e83e0eeda6f1037de2fec9 (diff)
downloadvolse-hubzilla-28943af494eae225b256b9771a5699a1b05d7a2f.tar.gz
volse-hubzilla-28943af494eae225b256b9771a5699a1b05d7a2f.tar.bz2
volse-hubzilla-28943af494eae225b256b9771a5699a1b05d7a2f.zip
Merge pull request #19 from redmatrix/master
updating from original codebase
Diffstat (limited to 'mod/magic.php')
-rw-r--r--mod/magic.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/mod/magic.php b/mod/magic.php
index 2fee87241..12679773b 100644
--- a/mod/magic.php
+++ b/mod/magic.php
@@ -105,6 +105,7 @@ function magic_init(&$a) {
$r = q("select * from channel left join hubloc on channel_hash = hubloc_hash where hubloc_addr = '%s' limit 1",
dbesc($delegate)
);
+
if($r && intval($r[0]['channel_id'])) {
$allowed = perm_is_allowed($r[0]['channel_id'],get_observer_hash(),'delegate');
if($allowed) {
@@ -112,6 +113,7 @@ function magic_init(&$a) {
$_SESSION['delegate'] = get_observer_hash();
$_SESSION['account_id'] = intval($r[0]['channel_account_id']);
change_channel($r[0]['channel_id']);
+
$delegation_success = true;
}
}