feat: add no-op when method to Entity base class for event handling
This commit is contained in:
@@ -17,5 +17,8 @@ class Entity(ABC):
|
||||
def _ensure_valid_state(self):
|
||||
pass
|
||||
|
||||
def when(self, event: DomainEvent) -> Self:
|
||||
return self
|
||||
|
||||
def clear_changes(self) -> Self:
|
||||
return replace(self, _changes=())
|
||||
|
||||
Reference in New Issue
Block a user