From 6052430b8525161f92d0c014db94aeade1127330 Mon Sep 17 00:00:00 2001 From: Yuwen Memon Date: Thu, 10 Jun 2021 15:17:00 -0700 Subject: [PATCH] Add beta for default rooms --- src/CONST.js | 1 + src/libs/Permissions.js | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/src/CONST.js b/src/CONST.js index d268f302177f..7fdac75ae542 100755 --- a/src/CONST.js +++ b/src/CONST.js @@ -12,6 +12,7 @@ const CONST = { IOU: 'IOU', PAY_WITH_EXPENSIFY: 'payWithExpensify', FREE_PLAN: 'freePlan', + DEFAULT_ROOMS: 'defaultRooms', }, BUTTON_STATES: { DEFAULT: 'default', diff --git a/src/libs/Permissions.js b/src/libs/Permissions.js index f0a981b350b3..384a5036f19a 100644 --- a/src/libs/Permissions.js +++ b/src/libs/Permissions.js @@ -43,9 +43,18 @@ function canUseFreePlan(betas) { return _.contains(betas, CONST.BETAS.FREE_PLAN) || canUseAllBetas(); } +/** + * @param {Array} betas + * @returns {Boolean} + */ +function canUseDefaultRooms(betas) { + return _.contains(betas, CONST.BETAS.DEFAULT_ROOMS) || canUseAllBetas(); +} + export default { canUseChronos, canUseIOU, canUsePayWithExpensify, canUseFreePlan, + canUseDefaultRooms, };