Migrate remaining places

This commit is contained in:
Yassine Guedidi 2022-08-25 23:34:56 +02:00
parent 481283bbee
commit 791b674cdc
5 changed files with 9 additions and 9 deletions

View file

@ -9,7 +9,7 @@ security:
providers:
administrators:
entity:
class: WallabagUserBundle:User
class: 'Wallabag\UserBundle\Entity\User'
property: username
fos_userbundle:
id: fos_user.user_provider.username_email

View file

@ -277,8 +277,8 @@ class InstallCommand extends ContainerAwareCommand
$em = $this->getContainer()->get('doctrine.orm.entity_manager');
// cleanup before insert new stuff
$em->createQuery('DELETE FROM WallabagCoreBundle:InternalSetting')->execute();
$em->createQuery('DELETE FROM WallabagCoreBundle:IgnoreOriginInstanceRule')->execute();
$em->createQuery('DELETE FROM Wallabag\CoreBundle\Entity\InternalSetting')->execute();
$em->createQuery('DELETE FROM Wallabag\CoreBundle\Entity\IgnoreOriginInstanceRule')->execute();
foreach ($this->getContainer()->getParameter('wallabag_core.default_internal_settings') as $setting) {
$newSetting = new InternalSetting();

View file

@ -123,19 +123,19 @@ services:
class: Wallabag\CoreBundle\Repository\EntryRepository
factory: [ "@doctrine.orm.default_entity_manager", getRepository ]
arguments:
- WallabagCoreBundle:Entry
- 'Wallabag\CoreBundle\Entity\Entry'
Wallabag\CoreBundle\Repository\TagRepository:
class: Wallabag\CoreBundle\Repository\TagRepository
factory: [ "@doctrine.orm.default_entity_manager", getRepository ]
arguments:
- WallabagCoreBundle:Tag
- 'Wallabag\CoreBundle\Entity\Tag'
Wallabag\CoreBundle\Repository\SiteCredentialRepository:
class: Wallabag\CoreBundle\Repository\SiteCredentialRepository
factory: [ "@doctrine.orm.default_entity_manager", getRepository ]
arguments:
- WallabagCoreBundle:SiteCredential
- 'Wallabag\CoreBundle\Entity\SiteCredential'
calls:
- [ setCrypto, [ '@Wallabag\CoreBundle\Helper\CryptoProxy' ] ]
@ -143,7 +143,7 @@ services:
class: Wallabag\CoreBundle\Repository\IgnoreOriginInstanceRuleRepository
factory: [ "@doctrine.orm.default_entity_manager", getRepository ]
arguments:
- WallabagCoreBundle:IgnoreOriginInstanceRule
- 'Wallabag\CoreBundle\Entity\IgnoreOriginInstanceRule'
Wallabag\CoreBundle\Helper\EntriesExport:
class: Wallabag\CoreBundle\Helper\EntriesExport

View file

@ -27,7 +27,7 @@ services:
class: Wallabag\UserBundle\Repository\UserRepository
factory: [ "@doctrine.orm.default_entity_manager", getRepository ]
arguments:
- WallabagUserBundle:User
- 'Wallabag\UserBundle\Entity\User'
Wallabag\UserBundle\EventListener\CreateConfigListener:
class: Wallabag\UserBundle\EventListener\CreateConfigListener

View file

@ -581,7 +581,7 @@ class EntryRestControllerTest extends WallabagApiTestCase
// Remove the created entry to avoid side effects on other tests
if (isset($content['id'])) {
$em = $this->client->getContainer()->get('doctrine.orm.entity_manager');
$entry = $em->getReference('WallabagCoreBundle:Entry', $content['id']);
$entry = $em->getReference(Entry::class, $content['id']);
$em->remove($entry);
$em->flush();
}