expressly/php-common

View on GitHub
src/Entity/Meta.php

Summary

Maintainability
A
0 mins
Test Coverage

__construct accesses the super-global variable $_SERVER.
Open

    public function __construct()
    {
        $this->setSender($_SERVER['SERVER_NAME']);
        $this->issuerData = new ArrayCollection();
    }
Severity: Minor
Found in src/Entity/Meta.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

Expected 1 newline at end of file; 0 found
Open

}
Severity: Minor
Found in src/Entity/Meta.php by phpcodesniffer

There are no issues that match your filters.

Category
Status