Skip to content

Commit 6dee81f

Browse files
committed
Tweak formatting
1 parent 1e4485f commit 6dee81f

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

app/Models/Thread.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
use Illuminate\Database\Eloquent\Model;
1919
use Illuminate\Database\Eloquent\Relations\BelongsTo;
2020
use Illuminate\Support\Carbon;
21+
use Illuminate\Support\Collection as SupportCollection;
2122
use Illuminate\Support\Str;
2223
use Spatie\Feed\Feedable;
2324
use Spatie\Feed\FeedItem;
@@ -192,10 +193,7 @@ public static function resolutionTime()
192193
}
193194
}
194195

195-
/**
196-
* retrieve 20 feed items with use of page parameter.
197-
*/
198-
public static function getFeedItems()
196+
public static function getFeedItems(): SupportCollection
199197
{
200198
return static::feedQuery()
201199
->paginate(static::FEED_PAGE_SIZE)

config/feed.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
use App\Models\Thread;
4+
35
return [
46
'feeds' => [
57
'forum' => [
@@ -11,14 +13,14 @@
1113
* You can also pass an argument to that method:
1214
* ['App\Model@getAllFeedItems', 'argument']
1315
*/
14-
'items' => ['App\Models\Thread@getFeedItems'],
16+
'items' => [Thread::class.'@getFeedItems'],
1517

1618
/*
1719
* The feed will be available on this url.
1820
*/
19-
'url' => '/forum/rss',
21+
'url' => '/forum/feed',
2022

21-
'title' => 'laravel.io Forum RSS Feed',
23+
'title' => 'Laravel.io Forum RSS Feed',
2224
],
2325
],
2426
];

0 commit comments

Comments
 (0)