From 63fe95dadc3880839a139e0dc50ba749ae01d640 Mon Sep 17 00:00:00 2001 From: Callum McIntyre Date: Sun, 19 Aug 2012 14:50:05 +0100 Subject: [PATCH 1/2] Changed timestamp function in database/eloquent/model.php from protected to public. Allows eloquent model timestamps to be updated without actually changing any data. git push fork minor/unprotect-eloquent-timestamps git status git # Signed-off-by: Callum McIntyre --- laravel/database/eloquent/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/laravel/database/eloquent/model.php b/laravel/database/eloquent/model.php index 61a7769c..d3d70fbb 100644 --- a/laravel/database/eloquent/model.php +++ b/laravel/database/eloquent/model.php @@ -445,7 +445,7 @@ abstract class Model { * * @return void */ - protected function timestamp() + public function timestamp() { $this->updated_at = new \DateTime; From f8fdcd894a1498025c0dca94485c11489cf6d51e Mon Sep 17 00:00:00 2001 From: Callum McIntyre Date: Sun, 19 Aug 2012 14:50:05 +0100 Subject: [PATCH 2/2] Changed timestamp function in eloquent/model.php to public --- laravel/database/eloquent/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/laravel/database/eloquent/model.php b/laravel/database/eloquent/model.php index 61a7769c..d3d70fbb 100644 --- a/laravel/database/eloquent/model.php +++ b/laravel/database/eloquent/model.php @@ -445,7 +445,7 @@ abstract class Model { * * @return void */ - protected function timestamp() + public function timestamp() { $this->updated_at = new \DateTime;