MatthewMi11er/wordpress-plugin-mi11er-utility

View on GitHub
includes/mi11er-utility/class-filters.php

Summary

Maintainability
A
0 mins
Test Coverage

Avoid unused parameters such as '$is_email'.
Open

    public function is_email_filter( $is_email, $email, $context ) {

UnusedFormalParameter

Since: 0.2

Avoid passing parameters to methods or constructors and then not using those parameters.

Example

class Foo
{
    private function bar($howdy)
    {
        // $howdy is not used
    }
}

Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter

Avoid unused parameters such as '$context'.
Open

    public function is_email_filter( $is_email, $email, $context ) {

UnusedFormalParameter

Since: 0.2

Avoid passing parameters to methods or constructors and then not using those parameters.

Example

class Foo
{
    private function bar($howdy)
    {
        // $howdy is not used
    }
}

Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter

Avoid unused parameters such as '$requested_url'.
Open

    public function redirect_canonical_filter( $redirect_url, $requested_url ) {

UnusedFormalParameter

Since: 0.2

Avoid passing parameters to methods or constructors and then not using those parameters.

Example

class Foo
{
    private function bar($howdy)
    {
        // $howdy is not used
    }
}

Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter

The parameter $redirect_url is not named in camelCase.
Open

    public function redirect_canonical_filter( $redirect_url, $requested_url ) {
        /**
         * Filter if we want to remove the 404 redirect guess.
         *
         * @param bool $prevent_guess Prevent the guess or not.

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $the_value is not named in camelCase.
Open

    public function https_local_ssl_verify_filter( $the_value ) {
        if ( WP_ENV === 'development' ) {
            $the_value = false;
        }
        return $the_value;

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $is_email is not named in camelCase.
Open

    public function is_email_filter( $is_email, $email, $context ) {
        return filter_var( $email, FILTER_VALIDATE_EMAIL );
    }

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $requested_url is not named in camelCase.
Open

    public function redirect_canonical_filter( $redirect_url, $requested_url ) {
        /**
         * Filter if we want to remove the 404 redirect guess.
         *
         * @param bool $prevent_guess Prevent the guess or not.

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The method https_local_ssl_verify_filter is not named in camelCase.
Open

    public function https_local_ssl_verify_filter( $the_value ) {
        if ( WP_ENV === 'development' ) {
            $the_value = false;
        }
        return $the_value;

CamelCaseMethodName

Since: 0.2

It is considered best practice to use the camelCase notation to name methods.

Example

class ClassName {
    public function get_name() {
    }
}

Source

The method is_email_filter is not named in camelCase.
Open

    public function is_email_filter( $is_email, $email, $context ) {
        return filter_var( $email, FILTER_VALIDATE_EMAIL );
    }

CamelCaseMethodName

Since: 0.2

It is considered best practice to use the camelCase notation to name methods.

Example

class ClassName {
    public function get_name() {
    }
}

Source

The method redirect_canonical_filter is not named in camelCase.
Open

    public function redirect_canonical_filter( $redirect_url, $requested_url ) {
        /**
         * Filter if we want to remove the 404 redirect guess.
         *
         * @param bool $prevent_guess Prevent the guess or not.

CamelCaseMethodName

Since: 0.2

It is considered best practice to use the camelCase notation to name methods.

Example

class ClassName {
    public function get_name() {
    }
}

Source

There are no issues that match your filters.

Category
Status