pi-freeflow 1.0.9 → 1.1.0
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/extensions/index.ts +7 -5
- package/package.json +1 -1
package/extensions/index.ts
CHANGED
|
@@ -1664,10 +1664,12 @@ export default async function (pi: ExtensionAPI) {
|
|
|
1664
1664
|
);
|
|
1665
1665
|
});
|
|
1666
1666
|
|
|
1667
|
-
pi.on("session_shutdown", () => {
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1667
|
+
pi.on?.("session_shutdown", () => {
|
|
1668
|
+
if (server) {
|
|
1669
|
+
log("info", "shutting down proxy...");
|
|
1670
|
+
server.close();
|
|
1671
|
+
rateLimitMap.clear();
|
|
1672
|
+
log("info", "shutdown complete");
|
|
1673
|
+
}
|
|
1672
1674
|
});
|
|
1673
1675
|
}
|