bugfixing
This commit is contained in:
parent
07b7d90d13
commit
3d538d4c6b
@ -345,16 +345,24 @@ function changeWatchList(newWatchList)
|
|||||||
}
|
}
|
||||||
|
|
||||||
function saveRules() {
|
function saveRules() {
|
||||||
localStorage.setItem('watchlist-ruleOfList', JSON.stringify(ruleOfList));
|
try {
|
||||||
|
localStorage?.setItem('watchlist-ruleOfList', JSON?.stringify(ruleOfList));
|
||||||
|
} catch(e) {
|
||||||
|
console.log('Failed saving indicator rules: ', e)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
onMount(async () => {
|
onMount(async () => {
|
||||||
|
try {
|
||||||
const savedRules = localStorage.getItem('watchlist-ruleOfList');
|
const savedRules = localStorage?.getItem('watchlist-ruleOfList');
|
||||||
if (savedRules) {
|
if (savedRules) {
|
||||||
ruleOfList = JSON.parse(savedRules);
|
ruleOfList = JSON.parse(savedRules);
|
||||||
}
|
}
|
||||||
|
} catch(e) {
|
||||||
|
console.log(ey)
|
||||||
|
}
|
||||||
|
|
||||||
checkedItems = new Set(ruleOfList.map(item => item.name))
|
checkedItems = new Set(ruleOfList.map(item => item.name))
|
||||||
allRows = sortIndicatorCheckMarks(allRows)
|
allRows = sortIndicatorCheckMarks(allRows)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user