-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Fix Update Subscription Details function when channel name is null #3884
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
Fix Update Subscription Details function when channel name is null #3884
Conversation
| }, | ||
| primaryProfile: function () { | ||
| return JSON.parse(JSON.stringify(this.profileList[0])) | ||
| return deepCopy(this.profileList[0]) |
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 updated all references of JSON.parse(JSON.stringify to use deepCopy to make the code more consistent
| return 0 | ||
| }).map((channel) => { | ||
| const subscriptions = deepCopy(this.profile.subscriptions).sort((a, b) => { | ||
| return a.name?.toLowerCase().localeCompare(b.name?.toLowerCase(), this.locale) |
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'm conditionally checking the name as there is a chance it is null due to the previous bug
* development: Translated using Weblate (Greek) Fix locales getting unnecessarily reprocessed for incremental builds (FreeTubeApp#3893) Fix the layout of the hashtag page (FreeTubeApp#3886) Translated using Weblate (French) Translated using Weblate (Swedish) Translated using Weblate (Indonesian) Translated using Weblate (Italian) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (Italian) Translated using Weblate (Portuguese) Cleanup some template conditionals (FreeTubeApp#3888) Add semantic roles to make the site more accessible (FreeTubeApp#3887) Translated using Weblate (Japanese) Fix Update Subscription Details function when channel name is null (FreeTubeApp#3884) Translated using Weblate (Spanish) Translated using Weblate (Romanian) Translated using Weblate (Hebrew) local API: Add support for PageHeader channel header (FreeTubeApp#3871) Translated using Weblate (Chinese (Traditional)) # Conflicts: # src/renderer/components/ft-list-playlist/ft-list-playlist.vue # src/renderer/components/ft-list-video/ft-list-video.vue # src/renderer/views/UserPlaylists/UserPlaylists.vue
* feature/playlist-2023-05: Translated using Weblate (Greek) Fix locales getting unnecessarily reprocessed for incremental builds (FreeTubeApp#3893) Fix the layout of the hashtag page (FreeTubeApp#3886) Translated using Weblate (French) Translated using Weblate (Swedish) Translated using Weblate (Indonesian) Translated using Weblate (Italian) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (Italian) Translated using Weblate (Portuguese) Cleanup some template conditionals (FreeTubeApp#3888) Add semantic roles to make the site more accessible (FreeTubeApp#3887) Translated using Weblate (Japanese) Fix Update Subscription Details function when channel name is null (FreeTubeApp#3884) Translated using Weblate (Spanish) Translated using Weblate (Romanian) Translated using Weblate (Hebrew) local API: Add support for PageHeader channel header (FreeTubeApp#3871) ! Fix invalid prop type warning Translated using Weblate (Chinese (Traditional))
Fix Update Subscription Details function when channel name is null
Pull Request Type
Related issue
closes #3869
Description
Fixes some issues for when a channel's name is null as well as simplifies the sorting we do on channels and centralizes the deepCopy function
Testing
Desktop