public function __construct(sfContext $context, sfEventDispatcher $dispatcher) { $this->mailer = $context->getMailer(); $this->dispatcher = $dispatcher; $this->serviceContainer = $context->getServiceContainer(); $this->initialize(); }