Merge "Allow patrol of uploads"
[lhc/web/wiklou.git] / includes / user / User.php
index 3e974e3..b406bac 100644 (file)
@@ -3309,6 +3309,18 @@ class User implements IDBAccessObject {
                );
        }
 
+       /**
+        * Check whether to enable new files patrol features for this user
+        * @return bool True or false
+        */
+       public function useFilePatrol() {
+               global $wgUseRCPatrol, $wgUseFilePatrol;
+               return (
+                       ( $wgUseRCPatrol || $wgUseFilePatrol )
+                               && ( $this->isAllowedAny( 'patrol', 'patrolmarks' ) )
+               );
+       }
+
        /**
         * Get the WebRequest object to use with this object
         *