diff options
author | Tobias Diekershoff <tobias.diekershoff@gmx.net> | 2009-04-10 14:25:25 +0200 |
---|---|---|
committer | Tobias Diekershoff <tobias.diekershoff@gmx.net> | 2009-04-10 14:25:25 +0200 |
commit | 4277a6818c6ac66158dfba3b94bdc1b2eb06b594 (patch) | |
tree | 99149b95d0bd0bfaac4b2ad3d646e8cc1da7f51a /lib/featureduserssection.php | |
parent | d1bf8b2143f597d9d1b1e7ff472532c596200011 (diff) | |
parent | 6cdc2ff444b8c76a3cdc5b8c6e9e7e7539d9b6cc (diff) |
Merge branch '0.7.x' of git://gitorious.org/laconica/dev into 0.7.x
Diffstat (limited to 'lib/featureduserssection.php')
-rw-r--r-- | lib/featureduserssection.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/featureduserssection.php b/lib/featureduserssection.php index aed94b1a5..4b9238d47 100644 --- a/lib/featureduserssection.php +++ b/lib/featureduserssection.php @@ -57,9 +57,14 @@ class FeaturedUsersSection extends ProfileSection $quoted[] = "'$nick'"; } + $table = "user"; + if(common_config('db','quote_identifiers')) { + $table = '"' . $table . '"'; + } + $qry = 'SELECT profile.* ' . - 'FROM profile JOIN user on profile.id = user.id ' . - 'WHERE user.nickname in (' . implode(',', $quoted) . ') ' . + 'FROM profile JOIN '. $table .' on profile.id = '. $table .'.id ' . + 'WHERE '. $table .'.nickname in (' . implode(',', $quoted) . ') ' . 'ORDER BY profile.created DESC '; $limit = PROFILES_PER_SECTION + 1; |