Merge "(bug 7851) Implement mediawiki.page.patrol.ajax"
[lhc/web/wiklou.git] / includes / resourceloader / ResourceLoaderUserTokensModule.php
index e1a5238..6d787c5 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 /**
+ * Resource loader module for user tokens.
+ *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
@@ -41,7 +43,8 @@ class ResourceLoaderUserTokensModule extends ResourceLoaderModule {
 
                return array(
                        'editToken' => $wgUser->getEditToken(),
-                       'watchToken' => ApiQueryInfo::getWatchToken(null, null),
+                       'patrolToken' => ApiQueryRecentChanges::getPatrolToken( null, null ),
+                       'watchToken' => ApiQueryInfo::getWatchToken( null, null ),
                );
        }
 
@@ -54,6 +57,13 @@ class ResourceLoaderUserTokensModule extends ResourceLoaderModule {
                        array( $this->contextUserTokens( $context ) ) );
        }
 
+       /**
+        * @return bool
+        */
+       public function supportsURLLoading() {
+               return false;
+       }
+
        /**
         * @return string
         */