Skip to content
Snippets Groups Projects

Resolve #3415938 "Cachefactory inject container"

3 files
+ 27
32
Compare changes
  • Side-by-side
  • Inline
Files
3
@@ -6,12 +6,9 @@
* Defines the cache backend factory.
*/
use Drupal\Core\Site\Settings;
use Symfony\Component\DependencyInjection\ContainerAwareInterface;
use Symfony\Component\DependencyInjection\ContainerAwareTrait;
use Psr\Container\ContainerInterface;
class CacheFactory implements CacheFactoryInterface, ContainerAwareInterface {
use ContainerAwareTrait;
class CacheFactory implements CacheFactoryInterface {
/**
* The site settings.
@@ -44,6 +41,18 @@ class CacheFactory implements CacheFactoryInterface, ContainerAwareInterface {
*/
protected $memoryDefaultBinBackends;
/**
* The service container.
*/
protected ContainerInterface $container;
/**
* Sets the service container.
*/
public function setContainer(ContainerInterface $container): void {
$this->container = $container;
}
/**
* Constructs CacheFactory object.
*
Loading