dist/jate/modules/File/File.php

Summary

Maintainability
A
0 mins
Test Coverage

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

        throw new JException($e->getMessage());
Severity: Minor
Found in dist/jate/modules/File/File.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 '48', column '19').
Open

        throw new JException("File [$_file] not found.");
Severity: Minor
Found in dist/jate/modules/File/File.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 '46', column '19').
Open

        throw new JException("Path must be a string.");
Severity: Minor
Found in dist/jate/modules/File/File.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 51.
Open

    protected function isCorrectUrl( $_url ) {
      return strpos(@get_headers($_url)[0],'200') === false ? false : true;
    }
Severity: Minor
Found in dist/jate/modules/File/File.php by phpmd

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

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

        throw new JException("Parameter must be an array.");
Severity: Minor
Found in dist/jate/modules/File/File.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 '28', column '19').
Open

        throw new JException("Parameter must be an array.");
Severity: Minor
Found in dist/jate/modules/File/File.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 '22', column '19').
Open

        throw new JException($e->getMessage());
Severity: Minor
Found in dist/jate/modules/File/File.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

There are no issues that match your filters.

Category
Status