1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-16 08:13:42 +00:00

Use more specific error message when no login to import were found (#16723)

Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
This commit is contained in:
Daniel James Smith
2025-10-03 23:08:23 +02:00
committed by GitHub
parent 72f7d8b96f
commit 96841129e6

View File

@@ -114,7 +114,11 @@ export class ImportChromeComponent implements OnInit, OnDestroy {
this.formGroup.controls.profile.value, this.formGroup.controls.profile.value,
); );
if (logins.length === 0) { if (logins.length === 0) {
throw "nothing to import"; return {
errors: {
message: this.i18nService.t("importNothingError"),
},
};
} }
const chromeLogins: ChromeLogin[] = []; const chromeLogins: ChromeLogin[] = [];
for (const l of logins) { for (const l of logins) {