X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiTokens.php;h=ff1914c8704b3a3317844d8ecab2c59b96bb1822;hb=ae031e237eab8e2023d0fe128f9749a8a43ea439;hp=fc2951a9db8bfaad7693bca5df6f84c464f999f3;hpb=49748181dd56ec97e7ba7c13e684a16abceb3cc0;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiTokens.php b/includes/api/ApiTokens.php index fc2951a9db..ff1914c870 100644 --- a/includes/api/ApiTokens.php +++ b/includes/api/ApiTokens.php @@ -1,9 +1,5 @@ [ 'ApiQueryRecentChanges', 'getPatrolToken' ] ]; + $types = [ 'patrol' => [ ApiQueryRecentChanges::class, 'getPatrolToken' ] ]; $names = [ 'edit', 'delete', 'protect', 'move', 'block', 'unblock', 'email', 'import', 'watch', 'options' ]; foreach ( $names as $name ) { - $types[$name] = [ 'ApiQueryInfo', 'get' . ucfirst( $name ) . 'Token' ]; + $types[$name] = [ ApiQueryInfo::class, 'get' . ucfirst( $name ) . 'Token' ]; } Hooks::run( 'ApiTokensGetTokenTypes', [ &$types ] );