@kumori/aurora-backend-handler 1.1.38 → 1.1.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/backend-handler.ts +8 -10
  2. package/package.json +1 -1
@@ -104,18 +104,16 @@ export class BackendHandler {
104
104
  environment.apiServer.apiVersion = apiVersion;
105
105
  let cookieReady = false;
106
106
  getUserHTTP().then(() => {
107
- cookieReady = true;
108
107
  this.changeRoute(route);
108
+ eventHelper.user.subscribe.load((data: UserData) => {
109
+ initializeGlobalWebSocketClient(token, "", "", data);
110
+ });
111
+ const loadedCb = (data: UserData) => {
112
+ updateUserComplete(data);
113
+ };
114
+ eventHelper.user.subscribe.loaded(loadedCb);
115
+ eventHelper.user.publish.load({} as UserData);
109
116
  })
110
- eventHelper.user.subscribe.load((data: UserData) => {
111
- if(cookieReady){
112
- initializeGlobalWebSocketClient(token, "", "", data);
113
- }
114
- });
115
- const loadedCb = (data: UserData) => {
116
- updateUserComplete(data);
117
- };
118
- eventHelper.user.subscribe.loaded(loadedCb);
119
117
  }
120
118
 
121
119
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kumori/aurora-backend-handler",
3
- "version": "1.1.38",
3
+ "version": "1.1.39",
4
4
  "description": "backend handler",
5
5
  "main": "backend-handler.ts",
6
6
  "scripts": {