decord/alpha/source/modules/analytics_sessions/SkippedClientHeartbeatUtil.tsx

27 lines
864 B
TypeScript
Raw Permalink Normal View History

2026-10-12 06:59:38 +00:00
// Module ID: 7192
// Function ID: 7193
// Name: SkippedClientHeartbeatUtil
2026-10-12 06:59:38 +00:00
// Dependencies: [1390, 7193, 2]
2026-08-14 17:33:39 +00:00
// Exports: shouldLogClientHeartbeatSkipped
2026-10-12 06:59:38 +00:00
// Module 7192 (SkippedClientHeartbeatUtil)
import sampleWithUserId from "sampleWithUserId" /* 7193 */;
2026-10-09 10:00:15 +00:00
import UserStore from "UserStore" /* 1390 */;
2026-10-03 08:58:59 +00:00
import size from "module_2" /* 2 */;
2026-08-14 17:33:39 +00:00
const result = size.fileFinishedImporting("modules/analytics_sessions/SkippedClientHeartbeatUtil.tsx");
2026-08-14 17:33:39 +00:00
export const shouldLogClientHeartbeatSkipped = function shouldLogClientHeartbeatSkipped() {
const currentUser = UserStore.getCurrentUser();
2026-08-14 17:33:39 +00:00
let tmp = null != currentUser;
if (tmp) {
let isStaffResult = currentUser.isStaff();
if (!isStaffResult) {
2026-10-03 08:58:59 +00:00
const obj2 = sampleWithUserId;
isStaffResult = obj2.sampleWithUserId(currentUser.id, 0.02);
2026-08-14 17:33:39 +00:00
}
tmp = isStaffResult;
}
return tmp;
};