Page MenuHomePhabricator

D12824.id42624.diff
No OneTemporary

D12824.id42624.diff

diff --git a/keyserver/src/updaters/thread-permission-updaters.js b/keyserver/src/updaters/thread-permission-updaters.js
--- a/keyserver/src/updaters/thread-permission-updaters.js
+++ b/keyserver/src/updaters/thread-permission-updaters.js
@@ -13,7 +13,11 @@
} from 'lib/permissions/thread-permissions.js';
import type { CalendarQuery } from 'lib/types/entry-types.js';
import { messageTypes } from 'lib/types/message-types-enum.js';
-import type { ThreadSubscription } from 'lib/types/subscription-types.js';
+import {
+ type ThreadSubscription,
+ defaultThreadSubscription,
+ joinThreadSubscription,
+} from 'lib/types/subscription-types.js';
import type {
ThreadPermissionsBlob,
ThreadRolePermissionsBlob,
@@ -912,11 +916,8 @@
return { membershipRows, relationshipChangeset };
}
-const defaultSubscriptionString = JSON.stringify({
- home: false,
- pushNotifs: false,
-});
-const joinSubscriptionString = JSON.stringify({ home: true, pushNotifs: true });
+const defaultSubscriptionString = JSON.stringify(defaultThreadSubscription);
+const joinSubscriptionString = JSON.stringify(joinThreadSubscription);
const membershipInsertBatchSize = 50;
diff --git a/lib/types/subscription-types.js b/lib/types/subscription-types.js
--- a/lib/types/subscription-types.js
+++ b/lib/types/subscription-types.js
@@ -37,4 +37,13 @@
pushNotifs: false,
};
-export { defaultThreadSubscription, threadSubscriptions };
+const joinThreadSubscription: ThreadSubscription = {
+ home: true,
+ pushNotifs: true,
+};
+
+export {
+ threadSubscriptions,
+ defaultThreadSubscription,
+ joinThreadSubscription,
+};

File Metadata

Mime Type
text/plain
Expires
Tue, Nov 26, 9:52 PM (20 h, 55 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2586447
Default Alt Text
D12824.id42624.diff (1 KB)

Event Timeline