Skip to content
This repository has been archived by the owner on Sep 4, 2023. It is now read-only.

Commit

Permalink
Can get username from postfix
Browse files Browse the repository at this point in the history
  • Loading branch information
jfoucher committed Feb 26, 2019
1 parent 8deaa28 commit 13bb1dd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Command/PostfixReceiveCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ protected function configure()
$this->addArgument('sender');
$this->addArgument('size');
$this->addArgument('recipient');
$this->addArgument('username', InputArgument::OPTIONAL);
}

protected function execute(InputInterface $input, OutputInterface $output)
Expand All @@ -58,8 +59,11 @@ protected function execute(InputInterface $input, OutputInterface $output)
$this->logger->info($input->getArgument('sender'));
$this->logger->info($input->getArgument('size'));
$this->logger->info($input->getArgument('recipient'));
$this->logger->info($input->getArgument('username'));
$message = new Message();
$message->data = $contents;
$message->username = $input->getArgument('username');

$this->dispatcher->dispatch(CustomSession::EVENT_SMTP_RECEIVED, new MessageReceivedEvent($message));
}
}

0 comments on commit 13bb1dd

Please sign in to comment.