mirror of
https://github.com/flarum/core.git
synced 2025-08-13 03:44:32 +02:00
fixed more attributes to match beta 8
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
|
||||
namespace Flarum\Notification;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Flarum\Database\AbstractModel;
|
||||
use Flarum\User\User;
|
||||
|
||||
@@ -70,7 +71,7 @@ class Notification extends AbstractModel
|
||||
*/
|
||||
public function read()
|
||||
{
|
||||
$this->read_at = time();
|
||||
$this->read_at = Carbon::now();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -11,6 +11,7 @@
|
||||
|
||||
namespace Flarum\Notification;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Flarum\User\User;
|
||||
|
||||
class NotificationRepository
|
||||
@@ -53,6 +54,6 @@ class NotificationRepository
|
||||
*/
|
||||
public function markAllAsRead(User $user)
|
||||
{
|
||||
Notification::where('user_id', $user->id)->update(['read_at' => time()]);
|
||||
Notification::where('user_id', $user->id)->update(['read_at' => Carbon::now()]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user