Explorar o código

Implemented AuthProvider on main wrapper

jnfrati %!s(int64=4) %!d(string=hai) anos
pai
achega
37345af936
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      dashboard/src/main/MainWrapper.tsx

+ 4 - 1
dashboard/src/main/MainWrapper.tsx

@@ -4,6 +4,7 @@ import { BrowserRouter } from "react-router-dom";
 import { ContextProvider } from "../shared/Context";
 import { ContextProvider } from "../shared/Context";
 import Main from "./Main";
 import Main from "./Main";
 import { RouteComponentProps, withRouter } from "react-router";
 import { RouteComponentProps, withRouter } from "react-router";
+import AuthProvider from "shared/auth/AuthContext";
 
 
 type PropsType = RouteComponentProps & {};
 type PropsType = RouteComponentProps & {};
 
 
@@ -14,7 +15,9 @@ class MainWrapper extends Component<PropsType, StateType> {
     let { history, location } = this.props;
     let { history, location } = this.props;
     return (
     return (
       <ContextProvider history={history} location={location}>
       <ContextProvider history={history} location={location}>
-        <Main />
+        <AuthProvider>
+          <Main />
+        </AuthProvider>
       </ContextProvider>
       </ContextProvider>
     );
     );
   }
   }