You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was thinking back to the combined index view issue (reverted in 72d06ba), and I think there might be a solution: we could run it through visibility scoping. This was much more confusing before with events, but now, all we need is an EloquentBuilder instance for Flarum\Discussion\Discussion. Unfortunately the query available under $search->getQuery() is a QueryBuilder, but we can wrap it in an EloquentBuilder to get access: core does a similar thing in https://github.com/flarum/core/blob/master/src/Post/Access/ScopePostVisibility.php#L55.
It would probably be a fair bit slower since visibility scoping is applied twice, but it should make it possible to restore combined view functionality.
The text was updated successfully, but these errors were encountered:
I was thinking back to the combined index view issue (reverted in 72d06ba), and I think there might be a solution: we could run it through visibility scoping. This was much more confusing before with events, but now, all we need is an EloquentBuilder instance for
Flarum\Discussion\Discussion
. Unfortunately the query available under$search->getQuery()
is aQueryBuilder
, but we can wrap it in anEloquentBuilder
to get access: core does a similar thing in https://github.com/flarum/core/blob/master/src/Post/Access/ScopePostVisibility.php#L55.It would probably be a fair bit slower since visibility scoping is applied twice, but it should make it possible to restore combined view functionality.
The text was updated successfully, but these errors were encountered: