BaseController   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 23
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
1
<?php
2
/**
3
 * This file is part of user_management
4
 * User: Sinan TURGUT <[email protected]>
5
 * Date: 24.06.2019
6
 * php version 7.2
7
 *
8
 * @category Assessment
9
 * @package  UserManagement
10
 * @author   Sinan TURGUT <[email protected]>
11
 * @license  See LICENSE file
12
 * @link     https://dev.sinanturgut.com.tr
13
 */
14
namespace UserManagement\Controllers;
15
16
use Interop\Container\ContainerInterface;
0 ignored issues
show
Bug introduced by
The type Interop\Container\ContainerInterface was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
17
18
/**
19
 * Class BaseController
20
 * @package UserManagement\Controllers
21
 */
22
class BaseController
23
{
24
    /**
25
     * @var ContainerInterface
26
     */
27
    protected $container;
28
    /**
29
     * @var mixed
30
     */
31
    protected $db;
32
    /**
33
     * @var
34
     */
35
    protected $generalConfig;
36
37
    /**
38
     * BaseController constructor.
39
     * @param ContainerInterface $container
40
     */
41
    public function __construct(ContainerInterface $container)
42
    {
43
        $this->container = $container;
44
        $this->db = $container->get('db');
45
    }
46
47
}