Import passwords for Microsoft Edge

This commit is contained in:
Sergey P
2022-08-17 07:20:15 +03:00
committed by Cepera
parent 2c673ae85c
commit 14cf9b0c34
2 changed files with 6 additions and 1 deletions
@@ -30,7 +30,10 @@ namespace {
std::pair<std::string, std::string> GetServiceAndAccountName() {
std::string service_name, account_name;
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
if (command_line->HasSwitch("import-chrome")) {
if (command_line->HasSwitch("import-edge")) {
service_name = std::string("Microsoft Edge Safe Storage");
account_name = std::string("Microsoft Edge");
} else if (command_line->HasSwitch("import-chrome")) {
service_name = std::string("Chrome Safe Storage");
account_name = std::string("Chrome");
} else if (command_line->HasSwitch("import-chromium") ||
@@ -63,6 +63,8 @@ void BraveProfileImportImpl::StartImport(
if (base::StartsWith(base::UTF16ToUTF8(source_profile.importer_name),
"Chrome", base::CompareCase::SENSITIVE)) {
command_line->AppendSwitch("import-chrome");
} else if (source_profile.importer_type == importer::TYPE_EDGE_CHROMIUM) {
command_line->AppendSwitch("import-edge");
} else if (base::StartsWith(base::UTF16ToUTF8(source_profile.importer_name),
"Chromium", base::CompareCase::SENSITIVE)) {
command_line->AppendSwitch("import-chromium");