-
Notifications
You must be signed in to change notification settings - Fork 902
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
Avoid cloning all profiles when subscribing and unsubscribing #5289
Avoid cloning all profiles when subscribing and unsubscribing #5289
Conversation
showToast(this.$t('Channel.Channel has been removed from your subscriptions')) | ||
|
||
if (profile._id === MAIN_PROFILE_ID && profileIds.length > 1) { | ||
showToast(this.$t('Channel.Removed subscription from {count} other channel(s)', { |
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.
suggestion (non-blocking, minor): Can do as a separate PR, as this is a pre-existing "issue", but we might as well pluralize the label instead of doing (s)
const profile = state.profileList.find(profile => profile._id === id) | ||
|
||
// use filter instead of splice in case the subscription appears multiple times | ||
// https://github.com/FreeTubeApp/FreeTube/pull/3468#discussion_r1179290877 |
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.
question (non-blocking, minor): Doesn't have to be considered for this PR, but wouldn't a user know that they're subscribed to a channel multiple times? That + the amount of time since this bug has been fixed (unsure exactly when) means maybe this is safe to make a splice
now.
* development: (120 commits) Update version number to v0.21.0 Remove limited donation methods (FreeTubeApp#5290) Translated using Weblate (Portuguese) Translated using Weblate (Portuguese (Portugal)) Avoid cloning all profiles when subscribing and unsubscribing (FreeTubeApp#5289) Fix arrow keys not working in the Create New Playlist prompt (FreeTubeApp#5243) Bump ws from 8.16.0 to 8.17.1 (FreeTubeApp#5291) Remove a few bits of unused code (FreeTubeApp#5287) Update About page to display correct Freetube logo based on currently set theme (FreeTubeApp#5126) Translated using Weblate (Croatian) * Update playlist page titles (FreeTubeApp#5271) Update Invidious instances list (FreeTubeApp#5288) Translated using Weblate (Polish) Bump the eslint group with 2 updates (FreeTubeApp#5275) Bump marked from 12.0.2 to 13.0.0 (FreeTubeApp#5276) Bump sass from 1.77.4 to 1.77.5 (FreeTubeApp#5277) Bump lefthook from 1.6.15 to 1.6.16 (FreeTubeApp#5279) Bump webpack from 5.91.0 to 5.92.0 (FreeTubeApp#5278) Update Flatpak PR Workflow to work with updated module (FreeTubeApp#5270) Translated using Weblate (Portuguese) ...
* development: (102 commits) Update version number to v0.21.0 Remove limited donation methods (FreeTubeApp#5290) Translated using Weblate (Portuguese) Translated using Weblate (Portuguese (Portugal)) Avoid cloning all profiles when subscribing and unsubscribing (FreeTubeApp#5289) Fix arrow keys not working in the Create New Playlist prompt (FreeTubeApp#5243) Bump ws from 8.16.0 to 8.17.1 (FreeTubeApp#5291) Remove a few bits of unused code (FreeTubeApp#5287) Update About page to display correct Freetube logo based on currently set theme (FreeTubeApp#5126) Translated using Weblate (Croatian) * Update playlist page titles (FreeTubeApp#5271) Update Invidious instances list (FreeTubeApp#5288) Translated using Weblate (Polish) Bump the eslint group with 2 updates (FreeTubeApp#5275) Bump marked from 12.0.2 to 13.0.0 (FreeTubeApp#5276) Bump sass from 1.77.4 to 1.77.5 (FreeTubeApp#5277) Bump lefthook from 1.6.15 to 1.6.16 (FreeTubeApp#5279) Bump webpack from 5.91.0 to 5.92.0 (FreeTubeApp#5278) Update Flatpak PR Workflow to work with updated module (FreeTubeApp#5270) Translated using Weblate (Portuguese) ...
Avoid cloning all profiles when subscribing and unsubscribing
Pull Request Type
Description
Here is a summary of the main improvements:
Testing
Subscribe to and unsubscribe from channels in invididual profiles as well as the "All Channels" one. Additionally make sure that the changes are correctly synced between windows.
Desktop