-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Open
Labels
bugIt's a bugIt's a bughighHigh priority issuesHigh priority issuesmobileAll mobile platformsAll mobile platforms
Description
Operating system
Android
Joplin version
3.4.7
Desktop version info
No response
Current behaviour
When using the manage profiles option on the mobile app to delete a profile, it does not actually delete profile data, it only de-references the profile in the profiles config. See:
joplin/packages/app-mobile/components/ProfileSwitcher/ProfileSwitcher.tsx
Lines 95 to 122 in 8018f12
| const onDeleteProfile = useCallback(async (profile: Profile) => { | |
| const doIt = async () => { | |
| try { | |
| const newConfig = deleteProfileById(profileConfig, profile.id); | |
| await saveProfileConfig(newConfig); | |
| setProfileConfigTime(Date.now()); | |
| } catch (error) { | |
| dialogs.prompt(_('Error'), error.message); | |
| } | |
| }; | |
| dialogs.prompt( | |
| _('Delete this profile?'), | |
| _('All data, including notes, notebooks and tags will be permanently deleted.'), | |
| [ | |
| { | |
| text: _('Delete profile "%s"', profile.name), | |
| onPress: () => doIt(), | |
| style: 'destructive', | |
| }, | |
| { | |
| text: _('Cancel'), | |
| onPress: () => {}, | |
| style: 'cancel', | |
| }, | |
| ], | |
| ); | |
| }, [dialogs, profileConfig, setProfileConfigTime]); |
For users with large profiles with many resources, this could be a massive waste of device storage, if the user deleted a profile and created a new one in its place, without being aware of the storage implications
Expected behaviour
The delete profile option should actually delete the profile data (the sqlite db and the resources)
Logs
No response
Metadata
Metadata
Assignees
Labels
bugIt's a bugIt's a bughighHigh priority issuesHigh priority issuesmobileAll mobile platformsAll mobile platforms