/**
  * @test
  */
 public function it_an_email_can_be_empty()
 {
     $id = CommitteeId::generate();
     $event = new CommitteeEmailChanged($id, null);
     $this->assertEquals($id, $event->committeeId());
     $this->assertEquals(null, $event->email());
 }
 public function whenCommitteeEmailChanged(CommitteeEmailChanged $event)
 {
     $committee = $this->committees->find((string) $event->committeeId());
     $committee = $committee->changeEmail($event->email());
     $this->committees->save($committee);
 }
 protected function applyCommitteeEmailChanged(CommitteeEmailChanged $event)
 {
     $this->email = $event->email();
 }