Fix a bug found in internal test caused by casting
This commit is contained in:
parent
bab8edaeba
commit
894a6cc54c
1 changed files with 8 additions and 7 deletions
|
|
@ -22,7 +22,7 @@ class EditPasswordTableViewController: PasswordEditorTableViewController {
|
||||||
|
|
||||||
override func shouldPerformSegue(withIdentifier identifier: String, sender: Any?) -> Bool {
|
override func shouldPerformSegue(withIdentifier identifier: String, sender: Any?) -> Bool {
|
||||||
if identifier == "saveEditPasswordSegue" {
|
if identifier == "saveEditPasswordSegue" {
|
||||||
let nameCell = tableView.cellForRow(at: IndexPath(row: 0, section: 0)) as! ContentTableViewCell
|
if let nameCell = tableView.cellForRow(at: IndexPath(row: 0, section: 0)) as? ContentTableViewCell {
|
||||||
if nameCell.getContent() != password?.name {
|
if nameCell.getContent() != password?.name {
|
||||||
let alertTitle = "Cannot Save Edit"
|
let alertTitle = "Cannot Save Edit"
|
||||||
let alertMessage = "Editing name is not supported."
|
let alertMessage = "Editing name is not supported."
|
||||||
|
|
@ -32,6 +32,7 @@ class EditPasswordTableViewController: PasswordEditorTableViewController {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue