decord/source/modules/guild_automod/ExperimentUtils.tsx

25 lines
1 KiB
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 9930
// Function ID: 9931
2026-07-20 16:05:17 +00:00
// Name: isInMentionRaidExperiment
2026-08-25 06:04:03 +00:00
// Dependencies: [9931, 2]
2026-07-20 16:05:17 +00:00
// Exports: isInMentionRaidExperiment, useIsMentionRaidExperimentEnabled
2026-08-25 06:04:03 +00:00
// Module 9930 (isInMentionRaidExperiment)
2026-08-24 06:08:38 +00:00
import set from "set" /* 2 */;
2026-08-25 06:04:03 +00:00
import experiment from "experiment" /* 9931 */;
2026-08-24 06:08:38 +00:00
const result = set.fileFinishedImporting("modules/guild_automod/ExperimentUtils.tsx");
2026-07-20 16:05:17 +00:00
export const isInMentionRaidExperiment = function isInMentionRaidExperiment(guildId) {
2026-08-24 06:08:38 +00:00
const AutomodMentionRaidLimit = experiment.AutomodMentionRaidLimit;
2026-07-20 16:05:17 +00:00
return AutomodMentionRaidLimit.getCurrentConfig({ guildId, location: "988d4e_3" }).enabled;
};
export const useIsMentionRaidExperimentEnabled = function useIsMentionRaidExperimentEnabled(id, arg1) {
2026-07-29 08:29:29 +00:00
let autoTrackExposure = arg1;
2026-07-20 16:05:17 +00:00
if (arg1 === undefined) {
2026-07-29 08:29:29 +00:00
autoTrackExposure = true;
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
const AutomodMentionRaidLimit = experiment.AutomodMentionRaidLimit;
2026-07-29 08:29:29 +00:00
return AutomodMentionRaidLimit.useExperiment({ guildId: id, location: "988d4e_4" }, { autoTrackExposure }).enabled;
2026-07-20 16:05:17 +00:00
};