autowp/external-login-service

View on GitHub
src/Google.php

Summary

Maintainability
A
2 hrs
Test Coverage

Showing 5 of 5 total issues

Method getData has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

public function getData(array $options): Result
{
$clientIDs = preg_split("/[[:space:]]+/isu", $this->options['clientId']);
 
foreach ($clientIDs as $clientID) {
Severity: Minor
Found in src/Google.php - About 1 hr to fix

    Function getData has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
    Open

    public function getData(array $options): Result
    {
    $clientIDs = preg_split("/[[:space:]]+/isu", $this->options['clientId']);
     
    foreach ($clientIDs as $clientID) {
    Severity: Minor
    Found in src/Google.php - About 55 mins to fix

    Avoid unused parameters such as '$params'.
    Open

    public function callback(array $params): array
    Severity: Minor
    Found in src/Google.php by phpmd

    syntax error, unexpected 'string' (T_STRING), expecting function (T_FUNCTION) or const (T_CONST)
    Open

    private string $idToken;
    Severity: Critical
    Found in src/Google.php by phan

    Avoid using static access to class '\Laminas\Uri\UriFactory' in method 'setSizeParam'.
    Open

    $uri = UriFactory::factory($url);
    Severity: Minor
    Found in src/Google.php by phpmd

    There are no issues that match your filters.

    Category
    Status