phossa2/config

View on GitHub

Showing 2 of 2 total issues

loadGlobal accesses the super-global variable $GLOBALS.
Open

    protected function loadGlobal(/*# string */ $group)
    {
        if (!isset($GLOBALS[$group])) {
            $this->throwError(
                Message::get(Message::CONFIG_GLOBAL_UNKNOWN, $group),
Severity: Minor
Found in src/Config/Config.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

loadGlobal accesses the super-global variable $GLOBALS.
Open

    protected function loadGlobal(/*# string */ $group)
    {
        if (!isset($GLOBALS[$group])) {
            $this->throwError(
                Message::get(Message::CONFIG_GLOBAL_UNKNOWN, $group),
Severity: Minor
Found in src/Config/Config.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

Severity
Category
Status
Source
Language