Add Cloudflare email and collaboration workflows
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
DROP INDEX IF EXISTS idx_watchers_user_folder_unique;
|
||||
DROP INDEX IF EXISTS idx_watchers_user_document_unique;
|
||||
@@ -0,0 +1,14 @@
|
||||
DELETE FROM watchers
|
||||
WHERE rowid NOT IN (
|
||||
SELECT MIN(rowid)
|
||||
FROM watchers
|
||||
GROUP BY user_id, document_id, folder_path
|
||||
);
|
||||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS idx_watchers_user_document_unique
|
||||
ON watchers(user_id, document_id)
|
||||
WHERE document_id IS NOT NULL;
|
||||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS idx_watchers_user_folder_unique
|
||||
ON watchers(user_id, folder_path)
|
||||
WHERE folder_path IS NOT NULL;
|
||||
Reference in New Issue
Block a user