File tree Expand file tree Collapse file tree 3 files changed +7
-8
lines changed
Expand file tree Collapse file tree 3 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 77 runs-on : ${{ matrix.os }}
88 strategy :
99 matrix :
10- node : ['12.x', ' 14.x']
11- os : [ubuntu-latest, windows-latest, macOS-latest ]
10+ node : ['14.x']
11+ os : [ubuntu-latest]
1212
1313 steps :
1414 - name : Checkout repo
Original file line number Diff line number Diff line change @@ -15,8 +15,7 @@ import React from 'react';
1515import ReactDOM from ' react-dom' ;
1616import ' ./index.less' ;
1717import App from ' ./App' ;
18- import { ApolloClient , ApolloProvider } from ' @apollo/client' ;
19- import { gqlClient } from ' graphql-react-client' ;
18+ import { ApolloClient , ApolloProvider , gqlClient } from ' graphql-react-client' ;
2019import authService from ' ./shared/services/authService' ;
2120
2221gqlClient .init ({
@@ -26,9 +25,9 @@ gqlClient.init({
2625});
2726
2827async function initScope(scope ) {
29- const sessionData : any = await authService .getSessionData ();
30- authService . login ( sessionData ) ;
31- return sessionData ?. mainRole === ' TYPE_CUSTOMER' ? ' customer' : scope ;
28+ const {token, mainRole} = await authService .getSessionData ();
29+ gqlClient . token = token ;
30+ return mainRole === ' TYPE_CUSTOMER' ? ' customer' : scope ;
3231}
3332let scope;
3433initScope (' privateScope' ).then (response => {
Original file line number Diff line number Diff line change 11{
2- "version" : " 0.1 .0" ,
2+ "version" : " 0.2 .0" ,
33 "license" : " MIT" ,
44 "main" : " dist/index.js" ,
55 "typings" : " dist/index.d.ts" ,
You can’t perform that action at this time.
0 commit comments