Fix tradecount in header not resetting to 0

This commit is contained in:
Matthias 2022-06-15 19:35:14 +02:00
parent 62f4ba1d23
commit fa493c22d2

View File

@ -215,12 +215,8 @@ export default defineComponent({
watch( watch(
() => botStore.activeBotorUndefined?.openTradeCount, () => botStore.activeBotorUndefined?.openTradeCount,
() => { () => {
console.log('openTradeCount changed'); if (settingsStore.openTradesInTitle === OpenTradeVizOptions.showPill) {
if ( setOpenTradesAsPill(botStore.activeBotorUndefined?.openTradeCount ?? 0);
settingsStore.openTradesInTitle === OpenTradeVizOptions.showPill &&
botStore.activeBotorUndefined?.openTradeCount
) {
setOpenTradesAsPill(botStore.activeBotorUndefined.openTradeCount);
} else if (settingsStore.openTradesInTitle === OpenTradeVizOptions.asTitle) { } else if (settingsStore.openTradesInTitle === OpenTradeVizOptions.asTitle) {
setTitle(); setTitle();
} }