forked from mirror/pixelfed
Merge pull request #2846 from pixelfed/staging
Update StatusEntityLexer, only add specific status types to PublicTimelineService
This commit is contained in:
commit
a35759cef1
|
@ -51,6 +51,7 @@
|
||||||
- Updated Profile, fix unauthenticated private profiles. ([9017f7c4](https://github.com/pixelfed/pixelfed/commit/9017f7c4))
|
- Updated Profile, fix unauthenticated private profiles. ([9017f7c4](https://github.com/pixelfed/pixelfed/commit/9017f7c4))
|
||||||
- Updated PublicApiController, impr home timeline perf. ([4fe42e5b](https://github.com/pixelfed/pixelfed/commit/4fe42e5b))
|
- Updated PublicApiController, impr home timeline perf. ([4fe42e5b](https://github.com/pixelfed/pixelfed/commit/4fe42e5b))
|
||||||
- Updated Timeline.vue, fix comment button. ([b6b5ce7c](https://github.com/pixelfed/pixelfed/commit/b6b5ce7c))
|
- Updated Timeline.vue, fix comment button. ([b6b5ce7c](https://github.com/pixelfed/pixelfed/commit/b6b5ce7c))
|
||||||
|
- Updated StatusEntityLexer, only add specific status types to PublicTimelineService. ([1fdcbe5b](https://github.com/pixelfed/pixelfed/commit/1fdcbe5b))
|
||||||
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
||||||
|
|
||||||
## [v0.11.0 (2021-06-01)](https://github.com/pixelfed/pixelfed/compare/v0.10.10...v0.11.0)
|
## [v0.11.0 (2021-06-01)](https://github.com/pixelfed/pixelfed/compare/v0.10.10...v0.11.0)
|
||||||
|
|
|
@ -150,17 +150,24 @@ class StatusEntityLexer implements ShouldQueue
|
||||||
public function deliver()
|
public function deliver()
|
||||||
{
|
{
|
||||||
$status = $this->status;
|
$status = $this->status;
|
||||||
|
$types = [
|
||||||
|
'photo',
|
||||||
|
'photo:album',
|
||||||
|
'video',
|
||||||
|
'video:album',
|
||||||
|
'photo:video:album'
|
||||||
|
];
|
||||||
|
|
||||||
if(config_cache('pixelfed.bouncer.enabled')) {
|
if(config_cache('pixelfed.bouncer.enabled')) {
|
||||||
Bouncer::get($status);
|
Bouncer::get($status);
|
||||||
}
|
}
|
||||||
|
|
||||||
if($status->uri == null && $status->scope == 'public') {
|
if($status->uri == null && $status->scope == 'public' && in_array($status->type, $types)) {
|
||||||
PublicTimelineService::add($status->id);
|
PublicTimelineService::add($status->id);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(config_cache('federation.activitypub.enabled') == true && config('app.env') == 'production') {
|
if(config_cache('federation.activitypub.enabled') == true && config('app.env') == 'production') {
|
||||||
StatusActivityPubDeliver::dispatch($this->status);
|
StatusActivityPubDeliver::dispatch($status);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue