Merge "Add .gitignore to the /skins directory"
[lhc/web/wiklou.git] / includes / api / ApiQueryLangLinks.php
index e6b02d7..a20b855 100644 (file)
@@ -67,6 +67,10 @@ class ApiQueryLangLinks extends ApiQueryBase {
                        );
                }
 
+               //FIXME: (follow-up) To allow extensions to add to the language links, we need
+               //       to load them all, add the extra links, then apply paging.
+               //       Should not be terrible, it's not going to be more than a few hundred links.
+
                // Note that, since (ll_from, ll_lang) is a unique key, we don't need
                // to sort by ll_title to ensure deterministic ordering.
                $sort = ( $params['dir'] == 'descending' ? ' DESC' : '' );
@@ -82,9 +86,9 @@ class ApiQueryLangLinks extends ApiQueryBase {
                                $this->addOption( 'ORDER BY', 'll_lang' . $sort );
                        } else {
                                $this->addOption( 'ORDER BY', array(
-                                                       'll_from' . $sort,
-                                                       'll_lang' . $sort
-                               ));
+                                       'll_from' . $sort,
+                                       'll_lang' . $sort
+                               ) );
                        }
                }
 
@@ -178,7 +182,8 @@ class ApiQueryLangLinks extends ApiQueryBase {
 
        public function getExamples() {
                return array(
-                       'api.php?action=query&prop=langlinks&titles=Main%20Page&redirects=' => 'Get interlanguage links from the [[Main Page]]',
+                       'api.php?action=query&prop=langlinks&titles=Main%20Page&redirects='
+                               => 'Get interlanguage links from the [[Main Page]]',
                );
        }