aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-07-16 22:48:05 -0700
committerfriendica <info@friendica.com>2013-07-16 22:48:05 -0700
commit4c30cddbfc105c0ea60f30594b760633e654cb0c (patch)
tree127e412b5f6bb038de8758b9d227fd32204b83e4 /include
parent6d447ace5c72e74145198ab1c3ebac2bf85d33cf (diff)
downloadvolse-hubzilla-4c30cddbfc105c0ea60f30594b760633e654cb0c.tar.gz
volse-hubzilla-4c30cddbfc105c0ea60f30594b760633e654cb0c.tar.bz2
volse-hubzilla-4c30cddbfc105c0ea60f30594b760633e654cb0c.zip
provide a controlling user for theme settings, not necessarily local_user() - can't test on my test site so moving into production and I'll debug it there.
Diffstat (limited to 'include')
-rw-r--r--include/Contact.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/Contact.php b/include/Contact.php
index 245682454..466d7f606 100644
--- a/include/Contact.php
+++ b/include/Contact.php
@@ -43,6 +43,8 @@ function channelx_by_n($id) {
function vcard_from_xchan($xchan, $observer = null, $mode = '') {
+ $a = get_app();
+
$connect = false;
if(local_user()) {
$r = q("select * from abook where abook_xchan = '%s' and abook_channel = %d limit 1",
@@ -53,6 +55,9 @@ function vcard_from_xchan($xchan, $observer = null, $mode = '') {
$connect = t('Connect');
}
+ if(array_key_exists('channel_id',$xchan))
+ $a->profile_uid = $xchan['channel_id'];
+
$url = (($observer)
? z_root() . '/magic?f=&dest=' . $xchan['xchan_url'] . '&addr=' . $xchan['xchan_addr']
: $xchan['xchan_url']