Set defaults for name_filter

This commit is contained in:
Narek Amirbekian
2022-03-15 15:13:04 -07:00
parent b38e9c45bf
commit 564458b106
3 changed files with 3 additions and 3 deletions

View File

@@ -14,7 +14,7 @@ export const reducers = (state = initialState, action) => {
return Object.assign({}, state, {
user_page: action.value.page,
user_data: action.value.data,
name_filter: action.value.name_filter,
name_filter: action.value.name_filter || "",
});
// Updates the client group model data and stores the page

View File

@@ -4,7 +4,7 @@ import { jhapiRequest } from "./jhapiUtil";
const withAPI = withProps(() => ({
updateUsers: (offset, limit, name_filter) =>
jhapiRequest(
`/users?offset=${offset}&limit=${limit}&name_filter=${name_filter}`,
`/users?offset=${offset}&limit=${limit}&name_filter=${name_filter || ""}`,
"GET"
).then((data) => data.json()),
updateGroups: (offset, limit) =>

File diff suppressed because one or more lines are too long