@bobfrankston/iflow 1.0.38 → 1.0.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.
- package/imaplib/ImapClient.js +6 -1
- package/package.json +2 -2
package/imaplib/ImapClient.js
CHANGED
|
@@ -93,7 +93,12 @@ export class ImapClient {
|
|
|
93
93
|
}
|
|
94
94
|
catch (err) {
|
|
95
95
|
console.error(`${new Date().toISOString()} Reconnection failed: ${imapError(err)}`);
|
|
96
|
-
//
|
|
96
|
+
// Stop reconnecting if server says too many connections — let it cool down
|
|
97
|
+
const errMsg = imapError(err);
|
|
98
|
+
if (errMsg.includes("max_userip_connections") || errMsg.includes("Too many simultaneous")) {
|
|
99
|
+
console.error(`${new Date().toISOString()} Connection limit reached — stopping reconnection`);
|
|
100
|
+
this.isDestroying = true; // Prevent further reconnect attempts
|
|
101
|
+
}
|
|
97
102
|
}
|
|
98
103
|
}
|
|
99
104
|
catch (err) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bobfrankston/iflow",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.39",
|
|
4
4
|
"description": "IMAP client wrapper library",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.ts",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"author": "",
|
|
24
24
|
"license": "ISC",
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@bobfrankston/oauthsupport": "^1.0.
|
|
26
|
+
"@bobfrankston/oauthsupport": "^1.0.20",
|
|
27
27
|
"imapflow": "^1.0.187"
|
|
28
28
|
},
|
|
29
29
|
"exports": {
|