Refactor database variable name for performance improvement
This commit is contained in:
@@ -28,6 +28,13 @@ DataBase.subscribe(data => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
$effect(() => {
|
||||||
|
//same as above, but for the other way around
|
||||||
|
if(DBState.db !== get(DataBase)){
|
||||||
|
DataBase.set(DBState.db)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
export function setDatabase(data:Database){
|
export function setDatabase(data:Database){
|
||||||
if(checkNullish(data.characters)){
|
if(checkNullish(data.characters)){
|
||||||
data.characters = []
|
data.characters = []
|
||||||
|
|||||||
Reference in New Issue
Block a user