Use computed properties instead of separate getter methods

This commit is contained in:
Danny Moesch 2018-06-23 20:42:56 +02:00 committed by Bob Sun
parent f76721d7fe
commit 904d04d71c
5 changed files with 44 additions and 62 deletions

View file

@ -164,7 +164,7 @@ class ExtensionViewController: UIViewController, UITableViewDataSource, UITableV
var decryptedPassword: Password?
do {
decryptedPassword = try self.passwordStore.decrypt(passwordEntity: passwordEntity, requestPGPKeyPassphrase: self.requestPGPKeyPassphrase)
let username = decryptedPassword?.getUsername() ?? decryptedPassword?.getLogin() ?? ""
let username = decryptedPassword?.username ?? decryptedPassword?.login ?? ""
let password = decryptedPassword?.password ?? ""
DispatchQueue.main.async {// prepare a dictionary to return
switch self.extensionAction {