Browse Source

Use setDirty(field) as true by default as the name suggest.

Mark Sch 7 years ago
parent
commit
9dd1b9b35d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/Datasource/EntityTrait.php

+ 2 - 2
src/Datasource/EntityTrait.php

@@ -805,10 +805,10 @@ trait EntityTrait
      *
      * @param string $property the field to set or check status for
      * @param bool $isDirty true means the property was changed, false means
-     * it was not changed
+     * it was not changed. Defaults to true.
      * @return $this
      */
-    public function setDirty($property, $isDirty)
+    public function setDirty($property, $isDirty = true)
     {
         if ($isDirty === false) {
             unset($this->_dirty[$property]);