Skip to content

Commit b4dd583

Browse files
committed
Add back freshTimestamp
1 parent d9760fa commit b4dd583

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/Jenssegers/Mongodb/Model.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,16 @@ protected function getDateFormat()
199199
return $this->dateFormat ?: 'Y-m-d H:i:s';
200200
}
201201

202+
/**
203+
* Get a fresh timestamp for the model.
204+
*
205+
* @return MongoDate
206+
*/
207+
public function freshTimestamp()
208+
{
209+
return new MongoDate;
210+
}
211+
202212
/**
203213
* Get the table associated with the model.
204214
*

0 commit comments

Comments
 (0)