decord/alpha/source/modules/chat/native/ChatChangesetUpdateTracker.tsx

34 lines
884 B
TypeScript
Raw Normal View History

2026-10-12 06:59:38 +00:00
// Module ID: 9602
// Function ID: 9603
// Name: ChatChangesetUpdateTracker
2026-07-23 10:11:24 +00:00
// Dependencies: [2]
2026-07-20 16:05:17 +00:00
// Exports: getAndIncrementChangesetIdForChat, getChangesetIdForChat
2026-10-12 06:59:38 +00:00
// Module 9602 (ChatChangesetUpdateTracker)
import size from "module_2" /* 2 */;
2026-08-24 06:08:38 +00:00
2026-07-20 16:05:17 +00:00
const weakMap = new WeakMap();
let result = size.fileFinishedImporting("modules/chat/native/ChatChangesetUpdateTracker.tsx");
2026-07-20 16:05:17 +00:00
export const getAndIncrementChangesetIdForChat = function getAndIncrementChangesetIdForChat(arg0) {
2026-07-29 08:29:29 +00:00
let num = weakMap.get(arg0);
2026-10-03 08:58:59 +00:00
const obj = weakMap;
2026-07-29 08:29:29 +00:00
if (num == null) {
num = 0;
2026-07-20 16:05:17 +00:00
}
const sum = num + 1;
2026-10-03 08:58:59 +00:00
const result = obj.set(arg0, sum);
2026-07-20 16:05:17 +00:00
return sum;
};
export const getChangesetIdForChat = function getChangesetIdForChat(current) {
let num = 0;
if (null != current) {
2026-07-29 08:29:29 +00:00
let num2 = weakMap.get(current);
if (num2 == null) {
num2 = 0;
2026-07-20 16:05:17 +00:00
}
num = num2;
}
return num;
};