-
-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#228: Rename property and increase stream history length issue-number #281
base: master
Are you sure you want to change the base?
#228: Rename property and increase stream history length issue-number #281
Conversation
Hi @telepcak , thanks for your time and contributions. I see you did both frontend and backend parts of the issue, that's nice. Here are some things I see from the pipeline and format:
Let me know if you need anything :) |
…stream-history-length
…ponent, openapi generated | [AntonioMrtz#228]
…y-length' of https://github.com/telepcak/SpotifyElectron into refactor/228-Rename-property-and-increase-stream-history-length
Hi, @AntonioMrtz , I hopefully fixed code according to proposed changes. Just leave a comment if sth still needs a change ! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, thanks for your time. Code looks mostly good, but there's a few things we have to fix. We wanna get rid of playback
word across the project so searching for this key word and refactor the naming convention should be done :) . Remember to star the project if you like it 😃
Electron/src/components/ShowAllItems/Items/ItemsAllSongsFromStreamHistory.tsx
Show resolved
Hide resolved
return ( | ||
<SongCard | ||
// eslint-disable-next-line react/no-array-index-key | ||
key={songItem.name} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would use ${songItem.name}-${songItem.artist}
userName, | ||
songName, | ||
); | ||
} catch (err) { | ||
console.log( | ||
`Unable to update User ${userName} playback history with Son ${songName}`, | ||
`Unable to update User ${userName} stream history with Son ${songName}`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you fix this typo? with Son
streamHistory.slice(0, 5).map((songItem) => { | ||
return ( | ||
<SongCard | ||
// eslint-disable-next-line react/no-array-index-key |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we delete // eslint-disable-next-line react/no-array-index-key
and use songItem.name-songItem.artist
?
@@ -30,7 +30,7 @@ const useFetchGetUserPlaybackHistory = (userName: string | undefined) => { | |||
fetchData(); | |||
}, [userName]); | |||
|
|||
return { playbackHistory, loading, error }; | |||
return { streamHistory: streamHistory, loading, error }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
streamHistory: streamHistory
is needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks mostly good. Just a few minor fixes. When they're checked I would run the pipelines and do a last test with all the app launched. Can you check npm run lint
and npm run test
outputs? There're some adjustments need to be done there
Description
Backend variable name refractored, fixed corresponding test, proposed change to show only 5 songs on frontend
Commit type
Refactor
Issue
#228
Proposed Changes
Variable name is simply refractored and frontend change to show only 5 songs in profile history is achieved through boolean variable and button to show all songs or only 5
Potential Impact
Screenshots
Additional Tasks
Assigned
@AntonioMrtz