Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3299519
D13268.id43996.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D13268.id43996.diff
View Options
diff --git a/lib/shared/thread-utils.js b/lib/shared/thread-utils.js
--- a/lib/shared/thread-utils.js
+++ b/lib/shared/thread-utils.js
@@ -397,7 +397,7 @@
): string {
let pendingThreadKey;
if (sourceMessageID && threadTypeIsThick(threadType)) {
- pendingThreadKey = `thick_sidebar/${sourceMessageID}`;
+ pendingThreadKey = `dm_sidebar/${sourceMessageID}`;
} else if (sourceMessageID) {
pendingThreadKey = `sidebar/${sourceMessageID}`;
} else {
@@ -425,7 +425,7 @@
const [threadTypeString, threadKey] = pendingThreadIDMatches[1].split('/');
let threadType;
- if (threadTypeString === 'thick_sidebar') {
+ if (threadTypeString === 'dm_sidebar') {
threadType = threadTypes.THICK_SIDEBAR;
} else if (threadTypeString === 'sidebar') {
threadType = threadTypes.SIDEBAR;
@@ -434,7 +434,7 @@
}
const threadTypeStringIsSidebar =
- threadTypeString === 'sidebar' || threadTypeString === 'thick_sidebar';
+ threadTypeString === 'sidebar' || threadTypeString === 'dm_sidebar';
const memberIDs = threadTypeStringIsSidebar ? [] : threadKey.split('+');
const sourceMessageID = threadTypeStringIsSidebar ? threadKey : null;
return {
diff --git a/lib/shared/thread-utils.test.js b/lib/shared/thread-utils.test.js
--- a/lib/shared/thread-utils.test.js
+++ b/lib/shared/thread-utils.test.js
@@ -36,7 +36,7 @@
memberIDs: [],
sourceMessageID: '12345',
};
- expect(parsePendingThreadID('pending/thick_sidebar/12345')).toStrictEqual(
+ expect(parsePendingThreadID('pending/dm_sidebar/12345')).toStrictEqual(
thickSidebarResult,
);
@@ -210,6 +210,6 @@
it('should return correct ID from thick sidebar input', () => {
expect(
getPendingThreadID(threadTypes.THICK_SIDEBAR, [], '12345'),
- ).toStrictEqual('pending/thick_sidebar/12345');
+ ).toStrictEqual('pending/dm_sidebar/12345');
});
});
diff --git a/lib/utils/validation-utils.js b/lib/utils/validation-utils.js
--- a/lib/utils/validation-utils.js
+++ b/lib/utils/validation-utils.js
@@ -112,7 +112,7 @@
'[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}';
const idSchemaRegex = `(?:(?:[0-9]+|${uuidRegex})\\|)?(?:[0-9]+|${uuidRegex})`;
-const pendingThreadIDRegex = `pending/(type[0-9]+/[0-9]+(\\+[0-9]+)*|(sidebar|thick_sidebar)/${idSchemaRegex})`;
+const pendingThreadIDRegex = `pending/(type[0-9]+/[0-9]+(\\+[0-9]+)*|(sidebar|dm_sidebar)/${idSchemaRegex})`;
const thickThreadIDRegex: RegExp = new RegExp(`^${uuidRegex}$`);
const chatNameMaxLength = 191;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Nov 18, 12:53 PM (17 h, 12 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2534961
Default Alt Text
D13268.id43996.diff (2 KB)
Attached To
Mode
D13268: Rename thick_sidebar -> dm_sidebar
Attached
Detach File
Event Timeline
Log In to Comment