Files
navidrome/ui/src/actions/serverEvents.js
T
Deluan 7adacbac0d Removed event.type from SSE, as it was causing the browser to hang.
Needs more investigation, but for now, back to the simple message format
2021-02-04 12:37:06 -05:00

20 lines
353 B
JavaScript

export const EVENT_SCAN_STATUS = 'scanStatus'
export const EVENT_SERVER_START = 'serverStart'
export const processEvent = (type, data) => {
return {
type,
data: data,
}
}
export const scanStatusUpdate = (data) => ({
type: EVENT_SCAN_STATUS,
data: data,
})
export const serverDown = () => ({
type: EVENT_SERVER_START,
data: {},
})