GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

IndexControllerFactory::createService()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
ccs 0
cts 0
cp 0
rs 10
cc 1
eloc 2
nc 1
nop 1
crap 2
1
<?php
2
/**
3
 * Smart image resizing (and manipulation) by url module for Zend Framework 3
4
 *
5
 * @link      http://github.com/tck/zf2-imageresizer for the canonical source repository
6
 * @copyright Copyright (c) 2017 Tobias Knab
7
 * 
8
 * For the full copyright and license information, please view the LICENSE.txt
9
 * file that was distributed with this source code.
10
 */
11
 
12
namespace TckImageResizer\Controller;
13
14
use Interop\Container\ContainerInterface;
15
use TckImageResizer\Service\ImageProcessing;
16
use Zend\ServiceManager\FactoryInterface;
17
use Zend\ServiceManager\ServiceLocatorInterface;
18
19
/**
20
 * Index controller factory
21
 * 
22
 * @package TckImageResizer
23
 */
24
class IndexControllerFactory implements FactoryInterface
0 ignored issues
show
Deprecated Code introduced by
The interface Zend\ServiceManager\FactoryInterface has been deprecated with message: Use Zend\ServiceManager\Factory\FactoryInterface instead.

This class, trait or interface has been deprecated. The supplier of the file has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the type will be removed from the class and what other constant to use instead.

Loading history...
25
{
26
    /**
27
     * Create an IndexController object
28
     *
29
     * @param  ContainerInterface $container
30 3
     * @param  string             $requestedName
31
     * @param  null|array         $options
32 3
     * @return IndexController
33 3
     */
34 3
    public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
35 3
    {
36
        return new IndexController($container->get(ImageProcessing::class));
37
    }
38
39
    public function createService(ServiceLocatorInterface $services)
40
    {
41
        return $this($services, IndexController::class);
42
    }
43
}
44