[COMPONENT][Language] Do not exclude notes without language from the feeds

This commit is contained in:
Diogo Peralta Cordeiro 2021-12-26 04:55:14 +00:00
parent 9d5e149dec
commit 21f585ef7e
Signed by: diogo
GPG Key ID: 18D2D35001FBFAB0

View File

@ -51,7 +51,7 @@ class Language extends Component
}
$notes = F\select(
$notes,
fn (Note $n) => \in_array($n->getLanguageId(), ActorLanguage::getActorRelatedLanguagesIds($actor)),
fn (Note $n) => is_null($n->getLanguageId()) || \in_array($n->getLanguageId(), ActorLanguage::getActorRelatedLanguagesIds($actor)),
);
return Event::next;