// Copyright 2024 The Lynx Authors. All rights reserved. // Licensed under the Apache License Version 2.0 that can be found in the // LICENSE file in the root directory of this source tree. import { clearMtsConfigCacheForTesting, isMtsEnabled } from '../../core/mts-capability.js'; import { isSdkVersionGt } from '../../utils.js'; let runOnBackgroundEnabled: boolean | undefined; /** * @internal */ function isRunOnBackgroundEnabled(): boolean { return runOnBackgroundEnabled ??= isSdkVersionGt(2, 15); } function clearConfigCacheForTesting(): void { clearMtsConfigCacheForTesting(); runOnBackgroundEnabled = undefined; } export { isMtsEnabled, isRunOnBackgroundEnabled, clearConfigCacheForTesting };