facade-bundle icon indicating copy to clipboard operation
facade-bundle copied to clipboard

facade has not been register

Open didix16 opened this issue 5 years ago • 0 comments

Hi, I'm new in using Facades into Symfony and I'm having troubles make then work...

I've been followed the steps in the documentation but when I'm trying to use the Facade this error arise:

RuntimeException: "App\Facades\Container" facade has not been register. in vendor/indragunawan/facade-bundle/AbstractFacade.php:55

This is the code of my Facade:

<?php


namespace App\Facades;


use Indragunawan\FacadeBundle\AbstractFacade;


/**
 * @method static object get(string $id)
 * Class Container
 */
class Container extends AbstractFacade
{

    /**
     * Get the registered id of the service.
     *
     * @return string
     */
    protected static function getFacadeAccessor()
    {
        return 'Symfony\Component\DependencyInjection\ContainerInterface';
    }
}

What I'm doing wrong?

BTW I'm using Symfony 3.4

Thanks in advance

didix16 avatar Nov 10 '20 10:11 didix16