Skip to content

Commit

Permalink
fix(clientportal): currentuser null error
Browse files Browse the repository at this point in the history
  • Loading branch information
Anu-Ujin Bat-Ulzii authored and Anu-Ujin Bat-Ulzii committed Jun 5, 2023
1 parent e886740 commit bedf91e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client-portal/modules/appContext.tsx
Expand Up @@ -24,7 +24,7 @@ type Props = {
};

function AppProvider({ children }: Props) {
const [currentUser, setCurrentUser] = React.useState({} as IUser);
const [currentUser, setCurrentUser] = React.useState(null);
const [notificationsCount, setNotificationsCount] = React.useState(0);

const userQuery = useQuery<UserQueryResponse>(gql(queries.currentUser));
Expand Down
2 changes: 1 addition & 1 deletion client-portal/modules/main/components/Header.tsx
Expand Up @@ -83,7 +83,7 @@ function Header({
};

const renderAuth = () => {
if (!config.ticketToggle) {
if (!config.ticketToggle || !config.taskToggle || !config.dealToggle) {
return null;
}

Expand Down

0 comments on commit bedf91e

Please sign in to comment.