Asymptix/Framework

View on GitHub

Showing 720 of 720 total issues

The method insert has a boolean flag argument $ignore, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function insert($ignore = false, $debug = false) {
Severity: Minor
Found in framework/db/DBObject.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method _get has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public static function _get($recordId, $debug = false) {
Severity: Minor
Found in framework/db/DBObject.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '330', column '20').
Open

        $ref = new \ReflectionClass(get_called_class());
Severity: Minor
Found in framework/db/DBObject.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Missing class import via use statement (line '73', column '31').
Open

                    throw new \Exception("Invalid simple key");
Severity: Minor
Found in framework/helpers/Naming.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Remove error control operator '@' on line 76.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

Remove error control operator '@' on line 86.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

Remove error control operator '@' on line 123.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

Remove error control operator '@' on line 128.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

The method _max has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public static function _max($field, $conditions = [], $debug = false) {
Severity: Minor
Found in framework/db/DBObject.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Remove error control operator '@' on line 74.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

Remove error control operator '@' on line 79.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

The method go has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function go($debug = false) {
Severity: Minor
Found in framework/db/DBPreparedQuery.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method save has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function save($debug = false) {
Severity: Minor
Found in framework/db/DBObject.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method _count has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public static function _count($conditions = [], $debug = false) {
Severity: Minor
Found in framework/db/DBObject.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method updateDBObject has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public static function updateDBObject($dbObject, $debug = false) {
Severity: Minor
Found in framework/db/DBCore.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '437', column '20').
Open

        $ref = new \ReflectionClass(get_called_class());
Severity: Minor
Found in framework/db/DBObject.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

The method selectDBObjectById has a boolean flag argument $debug, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function selectDBObjectById($objectId = null, $debug = false) {
Severity: Minor
Found in framework/db/DBSelector.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '576', column '20').
Open

        $ref = new \ReflectionClass(get_called_class());
Severity: Minor
Found in framework/db/DBObject.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Missing class import via use statement (line '44', column '44').
Open

        $oClass = new \ReflectionClass(new \Asymptix\db\DBQueryType);
Severity: Minor
Found in framework/db/DBQueryType.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Remove error control operator '@' on line 99.
Open

    public static function _get($ip, $type, $provider) {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new LocationDetectorException("Invalid IP address.");
        }

ErrorControlOperator

Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

Example

function foo($filePath) {
    $file = @fopen($filPath); // hides exceptions
    $key = @$array[$notExistingKey]; // assigns null to $key
}

Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

Severity
Category
Status
Source
Language