@ravshansbox/pi-quota 0.10.0 → 0.10.1
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/index.ts +2 -0
- package/package.json +1 -1
package/index.ts
CHANGED
|
@@ -312,6 +312,7 @@ export default function (pi: ExtensionAPI) {
|
|
|
312
312
|
}
|
|
313
313
|
|
|
314
314
|
function updateState(parsed: QuotaState) {
|
|
315
|
+
if (!ctxRef) return;
|
|
315
316
|
if (parsed.provider === 'anthropic') scheduleAnthropicPing(parsed);
|
|
316
317
|
const existing = states.find((s) => s.provider === parsed.provider);
|
|
317
318
|
if (!existing) {
|
|
@@ -666,5 +667,6 @@ export default function (pi: ExtensionAPI) {
|
|
|
666
667
|
|
|
667
668
|
pi.on('session_shutdown', () => {
|
|
668
669
|
stopTimers();
|
|
670
|
+
ctxRef = null;
|
|
669
671
|
});
|
|
670
672
|
}
|