We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b79b6d commit 776d4c2Copy full SHA for 776d4c2
src/RefactoringGuru/Memento/Structural/MementoStructural.php
@@ -93,10 +93,6 @@ public function save(): Memento
93
*/
94
public function restore(Memento $memento): void
95
{
96
- if (! $memento instanceof ConcreteMemento) {
97
- throw new \Exception("Unknown memento class ".get_class($memento));
98
- }
99
-
100
$this->state = $memento->getState();
101
echo "Originator: My state has changed to: {$this->state}\n";
102
}
0 commit comments