aboutsummaryrefslogtreecommitdiffstats
path: root/include/auth.php
diff options
context:
space:
mode:
authorMike Macgirvin <mike@macgirvin.com>2010-10-25 21:52:30 -0700
committerMike Macgirvin <mike@macgirvin.com>2010-10-25 21:52:30 -0700
commitc16f314ec348205f4741e0171335168720e652d2 (patch)
tree008aaaf38da2b478eca0a91a0cf4de7bb08dd26f /include/auth.php
parent1335ef759522ef9f877c8e8fd806cf9bba36297d (diff)
downloadvolse-hubzilla-c16f314ec348205f4741e0171335168720e652d2.tar.gz
volse-hubzilla-c16f314ec348205f4741e0171335168720e652d2.tar.bz2
volse-hubzilla-c16f314ec348205f4741e0171335168720e652d2.zip
two-way subscriptions working with federated social accounts
Diffstat (limited to 'include/auth.php')
-rw-r--r--include/auth.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/auth.php b/include/auth.php
index 7e04cb2e7..a54b24f08 100644
--- a/include/auth.php
+++ b/include/auth.php
@@ -41,7 +41,7 @@ if((x($_SESSION,'authenticated')) && (! ($_POST['auth-params'] === 'login'))) {
$_SESSION['my_url'] = $a->get_baseurl() . '/profile/' . $a->user['nickname'];
- $r = q("SELECT * FROM `contact` WHERE `uid` = %s AND `self` = 1 LIMIT 1",
+ $r = q("SELECT * FROM `contact` WHERE `uid` = %d AND `self` = 1 LIMIT 1",
intval($_SESSION['uid']));
if(count($r)) {
$a->contact = $r[0];
@@ -91,6 +91,7 @@ else {
$r = q("SELECT * FROM `contact` WHERE `uid` = %s AND `self` = 1 LIMIT 1",
intval($_SESSION['uid']));
if(count($r)) {
+ $a->contact = $r[0];
$a->cid = $r[0]['id'];
$_SESSION['cid'] = $a->cid;
}