Issues (17)

config/di/weather.php (1 issue)

1
<?php
2
/**
3
 * Configuration file for DI container.
4
 */
5
return [
6
    "services" => [
7
        "validera3" => [
8
            "shared" => true,
9
            "callback" => function () {
10
                $weatherapi = new \Anax\Ip3\Validera3();
11
                $cfg = $this->get("configuration");
0 ignored issues
show
Comprehensibility Best Practice introduced by
The variable $this seems to be never defined.
Loading history...
12
                //laddar filen med nyckeln
13
                $config = $cfg->load("weather_api.php");
14
                //skickar iväg nyckeln in i klassen. För att sen bli hämtbar
15
                $weatherapi->getWeatherApi($config["config"]["key"]);
16
                return $weatherapi;
17
            }
18
        ],
19
    ],
20
];
21