fix(user-management): 🐛 Fixed an issue where you couldn't 'unset' a users custom quality and root folders

pull/4432/head
tidusjar 3 years ago
parent 34cdbb8225
commit bae96af17f

@ -66,10 +66,22 @@ export class UserManagementUserComponent implements OnInit {
} else {
this.identityService.getNotificationPreferences().subscribe(x => this.notificationPreferences = x);
}
this.sonarrService.getQualityProfilesWithoutSettings().subscribe(x => this.sonarrQualities = x);
this.sonarrService.getRootFoldersWithoutSettings().subscribe(x => this.sonarrRootFolders = x);
this.radarrService.getQualityProfilesFromSettings().subscribe(x => this.radarrQualities = x);
this.radarrService.getRootFoldersFromSettings().subscribe(x => this.radarrRootFolders = x);
this.sonarrService.getQualityProfilesWithoutSettings().subscribe(x => {
this.sonarrQualities = x;
this.sonarrQualities.unshift({id: 0, name: "None"});
});
this.sonarrService.getRootFoldersWithoutSettings().subscribe(x => {
this.sonarrRootFolders = x;
this.sonarrRootFolders.unshift({id: 0, path: "None"});
});
this.radarrService.getQualityProfilesFromSettings().subscribe(x => {
this.radarrQualities = x;
this.radarrQualities.unshift({id: 0, name: "None"});
});
this.radarrService.getRootFoldersFromSettings().subscribe(x => {
this.radarrRootFolders = x;
this.radarrRootFolders.unshift({id: 0, path: "None"});
});
this.identityService.getUserAccessToken(this.userId).subscribe(x => this.accessToken = x);
@ -179,6 +191,7 @@ export class UserManagementUserComponent implements OnInit {
return;
}
this.identityService.updateUser(this.user).subscribe(x => {
if (x.successful) {
this.identityService.updateNotificationPreferences(this.notificationPreferences).subscribe();

Loading…
Cancel
Save