Resolve TODO (workaround is necessary)
This commit is contained in:
parent
0833d87f94
commit
0ee000a8a0
1 changed files with 2 additions and 6 deletions
|
|
@ -21,12 +21,8 @@ export const AlbumActions = ({
|
||||||
const dispatch = useDispatch()
|
const dispatch = useDispatch()
|
||||||
const translate = useTranslate()
|
const translate = useTranslate()
|
||||||
|
|
||||||
// TODO Not sure why data is accumulating tracks from previous plays... Needs investigation. For now, filter out
|
// Filter out tracks from other albums (cached by ReactAdmin)
|
||||||
// the unwanted tracks
|
const filteredData = ids.reduce((acc, id) => ({ ...acc, [id]: data[id] }), {})
|
||||||
const filteredData = ids.reduce((acc, id) => {
|
|
||||||
acc[id] = data[id]
|
|
||||||
return acc
|
|
||||||
}, {})
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<TopToolbar className={className} {...sanitizeListRestProps(rest)}>
|
<TopToolbar className={className} {...sanitizeListRestProps(rest)}>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue