Skip to content

Commit

Permalink
Fill and save event notifications for when users on clients choose au…
Browse files Browse the repository at this point in the history
…togenerated credentials
  • Loading branch information
amddg44 committed May 22, 2024
1 parent df4f762 commit 37fd6bf
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,7 @@ extension SecureVaultManager: AutofillSecureVaultDelegate {

if autofilldata.trigger == .passwordGeneration {
autogeneratedPassword = data.credentials?.autogenerated ?? false
NotificationCenter.default.post(name: .autofillFillEvent, object: nil)
}

// Account for cases when the user has manually changed an autogenerated password or private email
Expand Down Expand Up @@ -616,6 +617,7 @@ extension SecureVaultManager: AutofillSecureVaultDelegate {
var account = SecureVaultModels.WebsiteAccount(username: username, domain: domain, lastUsed: Date())
let credentials = try? vault?.storeWebsiteCredentials(SecureVaultModels.WebsiteCredentials(account: account, password: password))
account.id = String(credentials ?? -1)
NotificationCenter.default.post(name: .autofillSaveEvent, object: nil, userInfo: nil)
return account
}

Expand Down

0 comments on commit 37fd6bf

Please sign in to comment.