Dhii/collections-abstract-base

View on GitHub
src/AbstractHasher.php

Summary

Maintainability
A
0 mins
Test Coverage

The method _hash is not named in camelCase.
Open

    protected function _hash($value)
    {
        return is_scalar($value)
                ? $this->_hashScalar($value)
                : $this->_hashNonScalar($value);
Severity: Minor
Found in src/AbstractHasher.php by phpmd

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 _hashScalar is not named in camelCase.
Open

    protected function _hashScalar($value)
    {
        return sha1($value);
    }
Severity: Minor
Found in src/AbstractHasher.php by phpmd

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 _hashNonScalar is not named in camelCase.
Open

    protected function _hashNonScalar($value)
    {
        return is_object($value)
                ? $this->_hashScalar(spl_object_hash($value))
                : $this->_hashScalar(serialize($value));
Severity: Minor
Found in src/AbstractHasher.php by phpmd

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