From 2133d5a4e7fc694b097fe65282e557d99ee109ad Mon Sep 17 00:00:00 2001 From: CiaranG Date: Sun, 8 Mar 2009 16:16:10 +0000 Subject: PostgreSQL - some more fixes to make queries compatible with both databases. (submitted by oxygene) --- actions/postnotice.php | 2 +- actions/twittersettings.php | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'actions') diff --git a/actions/postnotice.php b/actions/postnotice.php index 0b4735296..c32d8ca94 100644 --- a/actions/postnotice.php +++ b/actions/postnotice.php @@ -79,7 +79,7 @@ class PostnoticeAction extends Action } $notice = Notice::staticGet('uri', $notice_uri); if (!$notice) { - $notice = Notice::saveNew($remote_profile->id, $content, 'omb', false, 0, $notice_uri); + $notice = Notice::saveNew($remote_profile->id, $content, 'omb', false, null, $notice_uri); if (is_string($notice)) { common_server_serror($notice, 500); return false; diff --git a/actions/twittersettings.php b/actions/twittersettings.php index a79859bbf..45725d3ff 100644 --- a/actions/twittersettings.php +++ b/actions/twittersettings.php @@ -186,12 +186,12 @@ class TwittersettingsAction extends ConnectSettingsAction $current_user = common_current_user(); - $qry = 'SELECT user.* ' . + $qry = 'SELECT "user".* ' . 'FROM subscription ' . - 'JOIN user ON subscription.subscribed = user.id ' . - 'JOIN foreign_link ON foreign_link.user_id = user.id ' . + 'JOIN "user" ON subscription.subscribed = "user".id ' . + 'JOIN foreign_link ON foreign_link.user_id = "user".id ' . 'WHERE subscriber = %d ' . - 'ORDER BY user.nickname'; + 'ORDER BY "user".nickname'; $user = new User(); -- cgit v1.2.3-54-g00ecf