fix nuisance timestamp error in API (#5759)

This commit is contained in:
Matt Fiddaman
2025-09-21 17:47:10 +01:00
committed by GitHub
parent 6b99497d5d
commit 59724d445f
3 changed files with 22 additions and 3 deletions

View File

@@ -42,7 +42,11 @@ export async function init(config: InitConfig = {}) {
export async function shutdown() {
if (actualApp) {
await actualApp.send('sync');
try {
await actualApp.send('sync');
} catch (e) {
// most likely that no budget is loaded, so the sync failed
}
await actualApp.send('close-budget');
actualApp = null;
}