Updating readme with a ModelHooks set/unset Method example

This commit is contained in:
Rob Porter
2021-04-01 16:04:59 -04:00
parent 16a4297992
commit 9fe65e7ed3
+2
View File
@@ -301,6 +301,8 @@ class MyCustomHook implements ModelHookInterface
}
$command->setProperty('custom', 'string', true, false, 'My custom property');
$command->unsetMethod('method');
$command->setMethod('method', $command->getMethodType($model, '\Some\Class'), ['$param']);
}
}
```