Change to object literal
This commit is contained in:
parent
feef7d49e9
commit
85756c78b4
1 changed files with 6 additions and 6 deletions
12
src/Roles.js
12
src/Roles.js
|
@ -16,12 +16,12 @@ limitations under the License.
|
||||||
import { _t } from './languageHandler';
|
import { _t } from './languageHandler';
|
||||||
|
|
||||||
export function levelRoleMap() {
|
export function levelRoleMap() {
|
||||||
const LEVEL_ROLE_MAP = {};
|
return {
|
||||||
LEVEL_ROLE_MAP[undefined] = _t('Default');
|
undefined: _t('Default'),
|
||||||
LEVEL_ROLE_MAP[0] = _t('User');
|
0: _t('User'),
|
||||||
LEVEL_ROLE_MAP[50] = _t('Moderator');
|
50: _t('Moderator'),
|
||||||
LEVEL_ROLE_MAP[100] = _t('Admin');
|
100: _t('Admin'),
|
||||||
return LEVEL_ROLE_MAP;
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function textualPowerLevel(level, userDefault) {
|
export function textualPowerLevel(level, userDefault) {
|
||||||
|
|
Loading…
Reference in a new issue