mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-17 20:11:27 +00:00
Merge pull request #5319 from pixelfed/staging
Update config, allow Beagle discover service to be disabled
This commit is contained in:
commit
49bae1da96
3 changed files with 13 additions and 0 deletions
|
@ -28,6 +28,10 @@
|
|||
- Update UserAccountDelete command, increase sharedInbox ttl from 12h to 14d ([be02f48a](https://github.com/pixelfed/pixelfed/commit/be02f48a))
|
||||
- Update HttpSignature, add signRaw method and improve error checking ([d4cf9181](https://github.com/pixelfed/pixelfed/commit/d4cf9181))
|
||||
- Update AP helpers, add forceBanCheck param to validateUrl method ([42424028](https://github.com/pixelfed/pixelfed/commit/42424028))
|
||||
- Update layout, add og:logo ([4cc576e1](https://github.com/pixelfed/pixelfed/commit/4cc576e1))
|
||||
- Update ReblogService, fix cache sync issues ([3de8ceca](https://github.com/pixelfed/pixelfed/commit/3de8ceca))
|
||||
- Update config, allow Beagle discover service to be disabled ([de4ce3c8](https://github.com/pixelfed/pixelfed/commit/de4ce3c8))
|
||||
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
||||
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
||||
|
||||
## [v0.12.3 (2024-07-01)](https://github.com/pixelfed/pixelfed/compare/v0.12.2...v0.12.3)
|
||||
|
|
|
@ -55,6 +55,10 @@ class BeagleService
|
|||
return [];
|
||||
}
|
||||
|
||||
if ((bool) config('instance.discover.beagle_api') == false) {
|
||||
return [];
|
||||
}
|
||||
|
||||
return Cache::remember(self::DISCOVER_CACHE_KEY, now()->addHours(6), function () {
|
||||
try {
|
||||
$res = Http::withOptions(['allow_redirects' => false])
|
||||
|
@ -92,6 +96,10 @@ class BeagleService
|
|||
return [];
|
||||
}
|
||||
|
||||
if ((bool) config('instance.discover.beagle_api') == false) {
|
||||
return [];
|
||||
}
|
||||
|
||||
return Cache::remember(self::DISCOVER_POSTS_CACHE_KEY, now()->addHours(1), function () {
|
||||
$posts = collect(self::getDiscover())
|
||||
->filter(function ($post) {
|
||||
|
|
|
@ -18,6 +18,7 @@ return [
|
|||
'tags' => [
|
||||
'is_public' => env('INSTANCE_PUBLIC_HASHTAGS', false),
|
||||
],
|
||||
'beagle_api' => env('PF_INSTANCE_USE_BEAGLE_API', true),
|
||||
],
|
||||
|
||||
'email' => env('INSTANCE_CONTACT_EMAIL'),
|
||||
|
|
Loading…
Reference in a new issue