mirror of
https://github.com/flarum/core.git
synced 2025-01-18 06:38:25 +01:00
Fix last_post_number potentially being null
This commit is contained in:
parent
7b06d38341
commit
569b9ab27e
@ -88,10 +88,10 @@ class DiscussionTableSeeder extends Seeder
|
||||
]);
|
||||
|
||||
$posts[] = $post;
|
||||
}
|
||||
|
||||
if (! $lastPost or $post->time >= $lastPost->time) {
|
||||
$lastPost = $post;
|
||||
if (! $lastPost or $post->time >= $lastPost->time) {
|
||||
$lastPost = $post;
|
||||
}
|
||||
}
|
||||
|
||||
if (rand(1, 20) == 1) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user