steamutils 1.2.19 → 1.2.20

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/SteamClient.js +2 -2
  2. package/package.json +1 -1
package/SteamClient.js CHANGED
@@ -385,7 +385,7 @@ function SteamClient({
385
385
 
386
386
  callEvent(events.disconnected, {eresult, msg})
387
387
 
388
- if (eresult === 3 && autoReconnect && !isLogOff) {
388
+ if (['ServiceUnavailable', 'NoConnection'].includes(msg) && autoReconnect && !isLogOff) {
389
389
  async function relogin(retry) {
390
390
  if (retry <= 0) {
391
391
  console.error("Cannot relogin")
@@ -411,7 +411,7 @@ function SteamClient({
411
411
  }
412
412
 
413
413
  await sleep(60000)
414
- const isSuccess = await relogin(20)
414
+ const isSuccess = await relogin(50)
415
415
  if (!isSuccess) {
416
416
  doClearIntervals()
417
417
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "steamutils",
3
- "version": "1.2.19",
3
+ "version": "1.2.20",
4
4
  "main": "index.js",
5
5
  "dependencies": {
6
6
  "axios": "^1.4.0",