removed proxy and added endpoints for methods
This commit is contained in:
+15
-16
@@ -165,7 +165,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
|
||||
|
||||
const { cookies } = req;
|
||||
|
||||
console.log("the cookoies", cookies);
|
||||
// console.log("the cookoies", cookies);
|
||||
|
||||
let token = await getToken();
|
||||
token = token.access_token;
|
||||
@@ -174,13 +174,13 @@ export const getServerSideProps = wrapper.getServerSideProps(
|
||||
|
||||
let providerConfig = await getProviderConfig();
|
||||
|
||||
console.log(
|
||||
"logout endpoint: ",
|
||||
providerConfig.end_session_endpoint,
|
||||
"\n",
|
||||
"redirect:",
|
||||
process.env.GG_REDIRECT_URI
|
||||
);
|
||||
// console.log(
|
||||
// "logout endpoint: ",
|
||||
// providerConfig.end_session_endpoint,
|
||||
// "\n",
|
||||
// "redirect:",
|
||||
// process.env.GG_REDIRECT_URI
|
||||
//);
|
||||
|
||||
store.dispatch(getGovGatewayConfig(providerConfig));
|
||||
|
||||
@@ -199,11 +199,11 @@ export const getServerSideProps = wrapper.getServerSideProps(
|
||||
]);
|
||||
|
||||
//const cookiesMaker = nookies.get(ctx)
|
||||
console.log(
|
||||
"acc details:",
|
||||
accountDetails,
|
||||
_.has(accountDetails, "errorCode") != false
|
||||
);
|
||||
// console.log(
|
||||
// "acc details:",
|
||||
// accountDetails,
|
||||
// _.has(accountDetails, "errorCode") != false
|
||||
// );
|
||||
|
||||
if (_.has(accountDetails, "errorCode") != false) {
|
||||
return {
|
||||
@@ -222,7 +222,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
|
||||
await getDetails(token, myCases, "myCases"),
|
||||
await getDetails(token, myRepresentations, "myRepresentations"),
|
||||
await getDetails(token, watchedCases, "myWatchedCases"),
|
||||
// await getDetails(awaitingSubmission),
|
||||
//await getDetails(awaitingSubmission),
|
||||
]);
|
||||
|
||||
store.dispatch(setAccountDetails(accountDetails));
|
||||
@@ -244,7 +244,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
|
||||
);
|
||||
|
||||
const getDetails = (token, resultsObj, detailsType) => {
|
||||
console.log(resultsObj);
|
||||
console.log(detailsType);
|
||||
let detailsArr = [];
|
||||
resultsObj = resultsObj.value;
|
||||
const detailsObj = resultsObj.map((searchDetail, index) => {
|
||||
@@ -271,7 +271,6 @@ const getDetails = (token, resultsObj, detailsType) => {
|
||||
);
|
||||
}
|
||||
});
|
||||
//console.log(detailsArr);
|
||||
return Promise.all(detailsArr);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user