Merge "Provide command to adjust phpunit.xml for code coverage"
[lhc/web/wiklou.git] / includes / auth / AuthenticationRequest.php
index 1a2442c..bc70d5e 100644 (file)
@@ -247,12 +247,18 @@ abstract class AuthenticationRequest {
 
        /**
         * Select a request by class name.
+        *
+        * @codingStandardsIgnoreStart
+        * @phan-template T
+        * @codingStandardsIgnoreEnd
         * @param AuthenticationRequest[] $reqs
         * @param string $class Class name
+        * @phan-param class-string<T> $class
         * @param bool $allowSubclasses If true, also returns any request that's a subclass of the given
         *   class.
         * @return AuthenticationRequest|null Returns null if there is not exactly
         *  one matching request.
+        * @phan-return T|null
         */
        public static function getRequestByClass( array $reqs, $class, $allowSubclasses = false ) {
                $requests = array_filter( $reqs, function ( $req ) use ( $class, $allowSubclasses ) {
@@ -376,7 +382,7 @@ abstract class AuthenticationRequest {
         * @return AuthenticationRequest
         */
        public static function __set_state( $data ) {
-               // @phan-suppress-next-line PhanTypeInstantiateAbstract
+               // @phan-suppress-next-line PhanTypeInstantiateAbstractStatic
                $ret = new static();
                foreach ( $data as $k => $v ) {
                        $ret->$k = $v;