wikimedia/mediawiki-core

View on GitHub
includes/api/ApiHookRunner.php

Summary

Maintainability
C
1 day
Test Coverage

ApiHookRunner has 44 functions (exceeds 20 allowed). Consider refactoring.
Open

class ApiHookRunner implements
    Hook\APIAfterExecuteHook,
    Hook\ApiCheckCanExecuteHook,
    Hook\ApiDeprecationHelpHook,
    Hook\ApiLogFeatureUsageHook,
Severity: Minor
Found in includes/api/ApiHookRunner.php - About 6 hrs to fix

    File ApiHookRunner.php has 332 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php
    
    namespace MediaWiki\Api;
    
    use Article;
    Severity: Minor
    Found in includes/api/ApiHookRunner.php - About 4 hrs to fix

      Method onApiQueryBaseBeforeQuery has 7 arguments (exceeds 4 allowed). Consider refactoring.
      Open

          public function onApiQueryBaseBeforeQuery( $module, &$tables, &$fields,
              &$conds, &$query_options, &$join_conds, &$hookData
      Severity: Major
      Found in includes/api/ApiHookRunner.php - About 50 mins to fix

        Method onApiMakeParserOptions has 6 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            public function onApiMakeParserOptions( $options, $title, $params, $module,
                &$reset, &$suppressCache
        Severity: Minor
        Found in includes/api/ApiHookRunner.php - About 45 mins to fix

          Method onTempUserCreatedRedirect has 6 arguments (exceeds 4 allowed). Consider refactoring.
          Open

                  Session $session,
                  UserIdentity $user,
                  string $returnTo,
                  string $returnToQuery,
                  string $returnToAnchor,
          Severity: Minor
          Found in includes/api/ApiHookRunner.php - About 45 mins to fix

            There are no issues that match your filters.

            Category
            Status