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