forked from AkkomaGang/akkoma-fe
Don't error out if we can't fetch reports
This commit is contained in:
parent
c3f829eb68
commit
64cb7443a8
1 changed files with 1 additions and 1 deletions
|
@ -650,7 +650,7 @@ const getReports = ({ state, limit, page, pageSize, credentials }) => {
|
|||
url = url + (args ? '?' + args : '')
|
||||
return fetch(url, { headers: authHeaders(credentials) })
|
||||
.then((data) => data.json())
|
||||
.then((data) => data.reports.map(parseReport))
|
||||
.then((data) => data?.reports?.map(parseReport) ?? [])
|
||||
}
|
||||
|
||||
const updateReportStates = ({ credentials, reports }) => {
|
||||
|
|
Loading…
Reference in a new issue