Issues (21)

config/di/weather.php (1 issue)

1
<?php
2
3
/**
4
 * Configuration file for request service.
5
 */
6
7
return [
8
    // Services to add to the container.
9
    "services" => [
10
        "weather" => [
11
            "shared" => true,
12
            "active" => true,
13
            "callback" => function () {
14
                $obj = new \Anax\Weather\Weather();
15
16
                $cfg = $this->get("configuration");
0 ignored issues
show
Comprehensibility Best Practice introduced by
The variable $this seems to be never defined.
Loading history...
17
18
                $config = $cfg->load("weather.php");
19
20
                $obj->setApiKey($config);
21
22
                return $obj;
23
            }
24
        ],
25
    ],
26
];
27