diff options
Diffstat (limited to 'src/helpers')
-rw-r--r-- | src/helpers/plan-helpers.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/helpers/plan-helpers.js b/src/helpers/plan-helpers.js index 19392585e..e0f1fd89a 100644 --- a/src/helpers/plan-helpers.js +++ b/src/helpers/plan-helpers.js | |||
@@ -33,3 +33,13 @@ export function i18nPlanName(planId, intl) { | |||
33 | 33 | ||
34 | return intl.formatMessage(messages[plan]); | 34 | return intl.formatMessage(messages[plan]); |
35 | } | 35 | } |
36 | |||
37 | export function getPlan(planId) { | ||
38 | if (!planId) { | ||
39 | throw new Error('planId is required'); | ||
40 | } | ||
41 | |||
42 | const plan = PLANS_MAPPING[planId]; | ||
43 | |||
44 | return plan; | ||
45 | } | ||