fix(settings): Fix initialization of store

Signed-off-by: Christopher Ng <chrng8@gmail.com>
pull/51336/head
Christopher Ng 2025-03-25 14:31:45 +07:00
parent 06dbcde4bf
commit f46f36b89d
1 changed files with 3 additions and 3 deletions

@ -36,14 +36,14 @@ const defaults = {
const state = {
users: [],
groups: [...usersSettings.systemGroups],
orderBy: usersSettings.sortGroups,
groups: [...(usersSettings.systemGroups ?? [])],
orderBy: usersSettings.sortGroups ?? GroupSorting.UserCount,
minPasswordLength: 0,
usersOffset: 0,
usersLimit: 25,
disabledUsersOffset: 0,
disabledUsersLimit: 25,
userCount: usersSettings.userCount,
userCount: usersSettings.userCount ?? 0,
showConfig: {
showStoragePath: localStorage.getItem('account_settings__showStoragePath') === 'true',
showUserBackend: localStorage.getItem('account_settings__showUserBackend') === 'true',