Fix tests

This commit is contained in:
Andrew Kingston 2024-09-04 15:41:10 +01:00
parent 238b1cecf1
commit 5b6809b913
No known key found for this signature in database
2 changed files with 4 additions and 5 deletions

View File

@ -2,7 +2,6 @@ import { writable } from "svelte/store"
export default class BudiStore { export default class BudiStore {
constructor(init, opts) { constructor(init, opts) {
this.initialState = init
const store = writable({ ...init }) const store = writable({ ...init })
/** /**
@ -33,8 +32,4 @@ export default class BudiStore {
}) })
} }
} }
reset = () => {
this.store.set({ ...this.initialState })
}
} }

View File

@ -13,6 +13,10 @@ export class RowActionStore extends BudiStore {
super(initialState) super(initialState)
} }
reset = () => {
this.store.set(initialState)
}
refreshRowActions = async sourceId => { refreshRowActions = async sourceId => {
if (!sourceId) { if (!sourceId) {
return return