Skip to content

Commit

Permalink
[PAY-1432] Fix chat playlist artist sometimes undefined (#3585)
Browse files Browse the repository at this point in the history
  • Loading branch information
dharit-tan authored Jun 14, 2023
1 parent 399d0b5 commit dc15518
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/common/src/audius-query/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ export type PerKeyState<NormalizedData> = {
export type QueryHookOptions = {
disabled?: boolean
shallow?: boolean
debug?: boolean
}

export type QueryHookResults<Data> = {
Expand Down
4 changes: 3 additions & 1 deletion packages/web/src/common/store/cache/tracks/utils/reformat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ export const reformat = <T extends TrackMetadata>(
): Track => {
const t = track
const withoutUser = omit(t, 'user')
const withImages = audiusBackendInstance.getTrackImages(withoutUser)
// audius-query denormalization expects track.user to contain the id of the owner.
const withUserIdAsUser = { ...withoutUser, user: t.owner_id }
const withImages = audiusBackendInstance.getTrackImages(withUserIdAsUser)
const withCosign = setIsCoSigned(withImages)
const withFieldVisibility = setFieldVisibility(withCosign)

Expand Down

0 comments on commit dc15518

Please sign in to comment.