From f5226cfbaa9522a56da2c27b53e222a44df2c874 Mon Sep 17 00:00:00 2001 From: Embbnux Ji Date: Tue, 7 Dec 2021 20:04:54 +0800 Subject: [PATCH] fix: disordered event sequence issue (#34) * fix: disordered event sequence issue * chore: remove unused code * chore: lint issue * chore: add tests * feat: clear session when drop session with 404 * fix: use partyId as event sequence key * chore: demo loading issue --- demo/index.js | 2 +- demo/redirect.html | 1 - package.json | 2 +- src/Session.ts | 64 +++++--------- src/index.ts | 48 +++++++++- test/index.test.ts | 203 ++++++++++++++++++++++++++++++++----------- test/mock/sdk.ts | 3 +- test/session.test.ts | 22 +++++ 8 files changed, 248 insertions(+), 97 deletions(-) diff --git a/demo/index.js b/demo/index.js index c2dead9..9a39728 100644 --- a/demo/index.js +++ b/demo/index.js @@ -84,7 +84,7 @@ $(function() { refreshCallList(); }); }); - $('.modal').modal('hide'); + $loadingModal.modal('hide'); } if (rcCallControl.ready) { onInitializedEvent(); diff --git a/demo/redirect.html b/demo/redirect.html index 88bffa8..09dc626 100644 --- a/demo/redirect.html +++ b/demo/redirect.html @@ -13,7 +13,6 @@

Loading

-