fix: PR fixes
This commit is contained in:
parent
1f6d272aa0
commit
21f3ee59ea
9 changed files with 52 additions and 43 deletions
|
|
@ -1,5 +1,14 @@
|
|||
import * as R from 'ramda'
|
||||
|
||||
const namespaces = {
|
||||
WALLETS: 'wallets',
|
||||
OPERATOR_INFO: 'operatorInfo',
|
||||
NOTIFICATIONS: 'notifications',
|
||||
SERVICES: 'services',
|
||||
LOCALE: 'locale',
|
||||
COMMISSIONS: 'commissions'
|
||||
}
|
||||
|
||||
const mapKeys = R.curry((fn, obj) =>
|
||||
R.fromPairs(R.map(R.adjust(0, fn), R.toPairs(obj)))
|
||||
)
|
||||
|
|
@ -23,4 +32,4 @@ const toNamespace = R.curry((key, config) =>
|
|||
mapKeys(it => `${key}_${it}`)(config)
|
||||
)
|
||||
|
||||
export { fromNamespace, toNamespace }
|
||||
export { fromNamespace, toNamespace, namespaces }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue