Skip to content

Commit

Permalink
add missing exception message
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidBadura committed Jan 25, 2024
1 parent f7e46d5 commit ce5eaf3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/Metadata/AggregateRoot/ClassIsNotAnAggregate.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,11 @@

final class ClassIsNotAnAggregate extends MetadataException
{
/**
* @param class-string $class
*/
public function __construct(string $class)
{
parent::__construct(sprintf('class %s is not an aggregate root', $class));
}
}
7 changes: 7 additions & 0 deletions src/Metadata/Event/ClassIsNotAnEvent.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,11 @@

final class ClassIsNotAnEvent extends MetadataException
{
/**
* @param class-string $class
*/
public function __construct(string $class)
{
parent::__construct(sprintf('class %s is not an event', $class));
}
}

0 comments on commit ce5eaf3

Please sign in to comment.