aboutsummaryrefslogtreecommitdiffstats
path: root/mod/dfrn_poll.php
diff options
context:
space:
mode:
authorzottel <github@zottel.net>2012-04-15 14:11:11 +0200
committerzottel <github@zottel.net>2012-04-15 14:11:11 +0200
commita2c4ce74871dbe9e640cdeafc1574bda5b7fe144 (patch)
treefce1c1b2d497adae72d77e09c6bf005c8900256b /mod/dfrn_poll.php
parent0bad8de0562a50fa93b0af5fd4cf8d7123a11b46 (diff)
parentf299749758112361ee6384cd75d11b2c3a57352a (diff)
downloadvolse-hubzilla-a2c4ce74871dbe9e640cdeafc1574bda5b7fe144.tar.gz
volse-hubzilla-a2c4ce74871dbe9e640cdeafc1574bda5b7fe144.tar.bz2
volse-hubzilla-a2c4ce74871dbe9e640cdeafc1574bda5b7fe144.zip
Merge remote branch 'upstream/master'
Diffstat (limited to 'mod/dfrn_poll.php')
-rw-r--r--mod/dfrn_poll.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/mod/dfrn_poll.php b/mod/dfrn_poll.php
index 5c2788983..436727a78 100644
--- a/mod/dfrn_poll.php
+++ b/mod/dfrn_poll.php
@@ -428,11 +428,13 @@ function dfrn_poll_content(&$a) {
break; // NOTREACHED
}
+ $nickname = $a->argv[1];
+
$r = q("SELECT `contact`.*, `user`.`username`, `user`.`nickname`
FROM `contact` LEFT JOIN `user` ON `contact`.`uid` = `user`.`uid`
WHERE `contact`.`blocked` = 0 AND `contact`.`pending` = 0
AND `user`.`nickname` = '%s' $sql_extra LIMIT 1",
- dbesc($a->argv[1])
+ dbesc($nickname)
);
if(count($r)) {
@@ -482,7 +484,7 @@ function dfrn_poll_content(&$a) {
));
}
- $profile = $r[0]['nickname'];
+ $profile = ((count($r) && $r[0]['nickname']) ? $r[0]['nickname'] : $nickname);
switch($destination_url) {
case 'profile':