fix(ui): provide better error message
parent
9b96d1b0d0
commit
c1b9f703b0
|
@ -18,7 +18,11 @@ export const writeLineProtocolAsync = (
|
|||
await writeLineProtocolAJAX(source, db, data, precision)
|
||||
dispatch(notify(notifyDataWritten()))
|
||||
} catch (response) {
|
||||
dispatch(notify(notifyDataWriteFailed(response.data.error)))
|
||||
dispatch(
|
||||
notify(
|
||||
notifyDataWriteFailed(response.data?.error || response.data?.message)
|
||||
)
|
||||
)
|
||||
throw response
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue