Deleting a collection should detach associated drafts from it (#5082)
Co-authored-by: Tom Moor <tom.moor@gmail.com>
This commit is contained in:
@@ -164,11 +164,12 @@ export default class NotificationHelper {
|
||||
const collectionIds = await recipient.collectionIds();
|
||||
|
||||
// Check the recipient has access to the collection this document is in. Just
|
||||
// because they are subscribed doesn't meant they "still have access to read
|
||||
// because they are subscribed doesn't mean they still have access to read
|
||||
// the document.
|
||||
if (
|
||||
recipient.email &&
|
||||
!recipient.isSuspended &&
|
||||
document.collectionId &&
|
||||
collectionIds.includes(document.collectionId)
|
||||
) {
|
||||
filtered.push(recipient);
|
||||
|
||||
@@ -31,7 +31,7 @@ type SearchOptions = {
|
||||
/** The query offset for pagination */
|
||||
offset?: number;
|
||||
/** Limit results to a collection. Authorization is presumed to have been done before passing to this helper. */
|
||||
collectionId?: string;
|
||||
collectionId?: string | null;
|
||||
/** Limit results to a shared document. */
|
||||
share?: Share;
|
||||
/** Limit results to a date range. */
|
||||
|
||||
Reference in New Issue
Block a user