1
0
Fork 0
mirror of synced 2024-07-07 23:46:11 +12:00

Merge branch 'feat-add-messaging-collections-in-config' into feat-messages-event-config

This commit is contained in:
prateek banga 2023-08-16 18:49:00 +05:30
commit ab655e69e6
2 changed files with 634 additions and 606 deletions

File diff suppressed because it is too large Load diff

View file

@ -522,6 +522,19 @@ Database::addFilter(
}
);
Database::addFilter(
'subQueryTargets',
function (mixed $value) {
return null;
},
function (mixed $value, Document $document, Database $database) {
return Authorization::skip(fn() => $database
->find('targets', [
Query::equal('userInternalId', [$document->getInternalId()]),
Query::limit(APP_LIMIT_SUBQUERY),
]));
}
);
/**
* DB Formats
*/