liiinder /
ramverk1-module
| 1 | <?php |
||
| 2 | /** |
||
| 3 | * Configuration file for request service. |
||
| 4 | */ |
||
| 5 | return [ |
||
| 6 | // Services to add to the container. |
||
| 7 | "services" => [ |
||
| 8 | "darksky" => [ |
||
| 9 | "shared" => true, |
||
| 10 | "callback" => function () { |
||
| 11 | $cfg = $this->get("configuration"); |
||
|
0 ignored issues
–
show
Comprehensibility
Best Practice
introduced
by
Loading history...
|
|||
| 12 | $config = $cfg->load("api_sample.php"); |
||
| 13 | $obj = new \Linder\Model\DarkSky($config["config"]["darksky"]); |
||
| 14 | return $obj; |
||
| 15 | } |
||
| 16 | ], |
||
| 17 | ], |
||
| 18 | ]; |
||
| 19 |