feat: add default _ensure_valid_state to Entity base class
This commit is contained in:
@@ -14,5 +14,8 @@ class Entity(ABC):
|
||||
def get_changes(self) -> tuple[DomainEvent, ...]:
|
||||
return self._changes
|
||||
|
||||
def _ensure_valid_state(self):
|
||||
pass
|
||||
|
||||
def clear_changes(self) -> Self:
|
||||
return replace(self, _changes=())
|
||||
|
||||
Reference in New Issue
Block a user