Skip to content

Commit

Permalink
fix: fetch settings after pinecil is re-connected
Browse files Browse the repository at this point in the history
  • Loading branch information
builder555 committed Jan 24, 2024
1 parent 996cbd2 commit a7398e5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ui/src/stores/appstore.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,10 @@ export const useAppStore = defineStore('appStore', () => {
isBusy.value = false;
});
socket.on('LIVE_DATA', (data) => {
if (error.value == 'Device not found') error.value = '';
if (error.value == 'Device not found' || error.value == 'Device disconnected') {
error.value = '';
init();
}
rawLiveData.value = data;
const watts = liveData.value.Watts;
if (watts > peakWatts.value) {
Expand Down

0 comments on commit a7398e5

Please sign in to comment.