/** * @see sfPluginConfiguration */ public function initialize() { // Yes, this can get called twice. This is Fabien's workaround: // http://trac.symfony-project.org/ticket/8026 if (!self::$registered) { $this->dispatcher->connect('a.getGlobalButtons', array('apostropheBlogPluginConfiguration', 'getGlobalButtons')); self::$registered = true; } }
/** * @see sfPluginConfiguration */ public function initialize() { // Yes, this can get called twice. This is Fabien's workaround: // http://trac.symfony-project.org/ticket/8026 if (!self::$registered) { $this->dispatcher->connect('a.getGlobalButtons', array('apostropheBlogPluginConfiguration', 'getGlobalButtons')); // This was inadvertently removed just prior to 1.4. Now apostrophe:migrate hooks up properly again $this->dispatcher->connect('command.post_command', array('aBlogEvents', 'listenToCommandPostCommandEvent')); $this->dispatcher->connect('a.get_categorizables', array($this, 'listenToGetCategorizables')); $this->dispatcher->connect('a.get_count_by_category', array($this, 'listenToGetCountByCategory')); self::$registered = true; } }