Implement a caching mechanism
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
namespace Krzysiej\RyobiCrawler\Controller;
|
||||
|
||||
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
||||
use Symfony\Component\Cache\Adapter\FilesystemAdapter;
|
||||
use Twig\Environment;
|
||||
use Illuminate\Database\Capsule\Manager as Capsule;
|
||||
|
||||
@@ -10,7 +11,7 @@ class BaseController extends AbstractController
|
||||
{
|
||||
protected Environment $twig;
|
||||
|
||||
public function __construct()
|
||||
public function __construct(protected FilesystemAdapter $cache)
|
||||
{
|
||||
$capsule = new Capsule;
|
||||
$capsule->addConnection(['driver' => 'sqlite', 'database' => __DIR__ . '/../../database.sqlite']);
|
||||
|
||||
Reference in New Issue
Block a user