Advertisement
Guest User

Untitled

a guest
Feb 21st, 2017
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. <?php
  2.  
  3. /**
  4. * init
  5. *
  6. * Initialise the modules resources/services.
  7. *
  8. * @param ModuleManagerInterface $moduleManager The module manager instance.
  9. */
  10. public function init(ModuleManagerInterface $moduleManager)
  11. {
  12. $eventManager = $moduleManager->getEventManager()->getSharedManager();
  13.  
  14. if (Console::isConsole()) {
  15. $eventManager->attach('doctrine', 'loadCli.post', [$this, 'loadCurrentClientViaCliOption'], -999);
  16. $eventManager->attach('doctrine', 'loadCli.post', [$this, 'loadEntityManagerViaCliOption'], -1000);
  17. }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement