koselig/library

View on GitHub
src/Providers/WordpressServiceProvider.php

Summary

Maintainability
A
0 mins
Test Coverage

addSidebarSupport accesses the super-global variable $GLOBALS.
Open

    public function addSidebarSupport()
    {
        collect(config('sidebars'))->each(function ($value) {
            register_sidebar(array_merge([
                'name' => '',

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

Multi-line function call not indented correctly; expected 8 spaces but found 16
Open

                true)['extra']['wordpress-install-dir'] . '/');

Closing parenthesis of a multi-line function call must be on a line by itself
Open

                true)['extra']['wordpress-install-dir'] . '/');

Opening parenthesis of a multi-line function call must be the last content on the line
Open

        define('WP_PATH', json_decode(file_get_contents($this->app->basePath() . DIRECTORY_SEPARATOR . 'composer.json'),

There are no issues that match your filters.

Category
Status