mirror of
https://github.com/flarum/core.git
synced 2025-08-01 22:20:21 +02:00
Rename column for consistency
This commit is contained in:
@@ -71,7 +71,7 @@ class User extends Model
|
||||
'join_time',
|
||||
'last_seen_time',
|
||||
'read_time',
|
||||
'notification_read_time'
|
||||
'notifications_read_time'
|
||||
];
|
||||
|
||||
/**
|
||||
@@ -295,7 +295,7 @@ class User extends Model
|
||||
*/
|
||||
public function markNotificationsAsRead()
|
||||
{
|
||||
$this->notification_read_time = time();
|
||||
$this->notifications_read_time = time();
|
||||
|
||||
return $this;
|
||||
}
|
||||
@@ -432,7 +432,7 @@ class User extends Model
|
||||
{
|
||||
return $this->notifications()
|
||||
->whereIn('type', $this->getAlertableNotificationTypes())
|
||||
->where('time', '>', $this->notification_read_time ?: 0)
|
||||
->where('time', '>', $this->notifications_read_time ?: 0)
|
||||
->where('is_read', 0)
|
||||
->where('is_deleted', 0)
|
||||
->count($this->getConnection()->raw('DISTINCT type, subject_id'));
|
||||
|
Reference in New Issue
Block a user