Add: display error message

This commit is contained in:
eight 2019-10-12 19:56:26 +08:00
parent cecadcdf3e
commit 6be5385314

View File

@ -123,7 +123,13 @@ document.onclick = e => {
} }
return 'syncing...'; return 'syncing...';
} }
return status.state.endsWith('ing') ? status.state + '...' : status.state; if (status.state.endsWith('ing')) {
return status.state + '...';
}
if (status.errorMessage) {
return status.errorMessage;
}
return status.state;
} }
connectButton.addEventListener('click', e => { connectButton.addEventListener('click', e => {