allow unprotected pages

This commit is contained in:
Sebastian Sdorra
2018-07-13 10:57:11 +02:00
parent 8ff84abf67
commit 5c59c6bac6
19 changed files with 567 additions and 450 deletions

View File

@@ -1,5 +1,5 @@
// @flow
import { apiClient, PAGE_NOT_FOUND_ERROR } from "../../apiclient";
import { apiClient, NOT_FOUND_ERROR } from "../../apiclient";
import type { User } from "../types/User";
import { ThunkDispatch } from "redux-thunk";
@@ -61,7 +61,7 @@ export function fetchUsers() {
dispatch(fetchUsersSuccess(data));
})
.catch(err => {
if (err === PAGE_NOT_FOUND_ERROR) {
if (err === NOT_FOUND_ERROR) {
dispatch(usersNotFound(USERS_URL));
} else {
dispatch(failedToFetchUsers(USERS_URL, err));