Closed ndinh215 closed 8 years ago
Some hardcode made this bundle not able to run both with Symfony 2 and 3. For example:
$classes = [
'Symfony\Component\Validator\Validator' => '/Resources/translations',
'Symfony\Component\Form\Form' => '/Resources/translations',
'Symfony\Component\Security\Core\Exception\AuthenticationException' => '/../../Resources/translations',
];
It needs to be refactored. I will wait for your decision, @saimaz . Thanks.
I fixed it, please check. Thanks.
Sorry, I've missed that we are checking namespace. It's already checked by Symfony, no need to check it twice. Actually, we don't need validateBundle function. Just request it from the kernel, if bundle won't exist kernel will throw an exception.
@saimaz , you are correct. Without a bundle existence, it will throw the exception:
Bundle "bundle name" does not exist or it is not enabled. Maybe you forgot to add it in the registerBundles() method of your AppKernel.php file?
Thanks.
I removed it. Please check. Thanks.
I implemented the issue #64 . Please review it. Thanks.