Fix r38302:
authorAryeh Gregor <simetrical@users.mediawiki.org>
Thu, 31 Jul 2008 16:34:33 +0000 (16:34 +0000)
committerAryeh Gregor <simetrical@users.mediawiki.org>
Thu, 31 Jul 2008 16:34:33 +0000 (16:34 +0000)
* PHP syntax error: mixing double and single quotes
* Probably an SQL syntax error too, due to lack of a space, unless "wl_user = 123ORDER BY wl_title" works in non-MySQL databases.  It doesn't in MySQL, and if it does in other engines, it probably shouldn't.  :)

includes/WatchlistEditor.php

index 54f9d81..d135230 100644 (file)
@@ -208,8 +208,8 @@ class WatchlistEditor {
                $sql = "SELECT wl_namespace, wl_title, page_id, page_len, page_is_redirect
                        FROM {$watchlist} LEFT JOIN {$page} ON ( wl_namespace = page_namespace
                        AND wl_title = page_title ) WHERE wl_user = {$uid}";
-               if ( ! $dbr->implicitOrderby() ) {
-                       $sql .= "ORDER BY wl_title';
+               if ( !$dbr->implicitOrderby() ) {
+                       $sql .= ORDER BY wl_title';
                }
                $res = $dbr->query( $sql, __METHOD__ );
                if( $res && $dbr->numRows( $res ) > 0 ) {