Use interface instead of concrete classe

This commit is contained in:
Pierre Rudloff 2016-10-13 16:34:57 +02:00
parent 98839d277e
commit 5de8e9d8cc

View file

@ -6,7 +6,7 @@ namespace Alltube\Controller;
use Alltube\Config; use Alltube\Config;
use Alltube\VideoDownload; use Alltube\VideoDownload;
use Slim\Container; use Interop\Container\ContainerInterface;
use Slim\Http\Request; use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
use Slim\Http\Stream; use Slim\Http\Stream;
@ -42,7 +42,7 @@ class FrontController
* *
* @param Container $container Slim dependency container * @param Container $container Slim dependency container
*/ */
public function __construct(Container $container) public function __construct(ContainerInterface $container)
{ {
$this->config = Config::getInstance(); $this->config = Config::getInstance();
$this->download = new VideoDownload(); $this->download = new VideoDownload();