From 421c15582a6ef69de309c04df898dd4b59c79bf7 Mon Sep 17 00:00:00 2001 From: Yishi Lin Date: Fri, 7 Apr 2017 01:59:03 +0800 Subject: [PATCH] Fix missing navigation titles - Fix bugs introduced in af9d4f1 --- pass/Base.lproj/Main.storyboard | 14 +++++++------- .../BasicStaticTableViewController.swift | 4 +++- .../PasswordEditorTableViewController.swift | 5 ++++- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/pass/Base.lproj/Main.storyboard b/pass/Base.lproj/Main.storyboard index 1b77cd9..0390e55 100644 --- a/pass/Base.lproj/Main.storyboard +++ b/pass/Base.lproj/Main.storyboard @@ -638,10 +638,10 @@ - + - + @@ -718,7 +718,7 @@ - + @@ -732,7 +732,7 @@ - + @@ -753,10 +753,10 @@ - + - + @@ -780,7 +780,7 @@ - + diff --git a/pass/Controllers/BasicStaticTableViewController.swift b/pass/Controllers/BasicStaticTableViewController.swift index 41898b9..a0d7536 100644 --- a/pass/Controllers/BasicStaticTableViewController.swift +++ b/pass/Controllers/BasicStaticTableViewController.swift @@ -29,7 +29,9 @@ class BasicStaticTableViewController: UITableViewController, MFMailComposeViewCo override func viewDidLoad() { super.viewDidLoad() - navigationItem.title = navigationItemTitle + if navigationItemTitle != nil { + navigationItem.title = navigationItemTitle + } } override func numberOfSections(in tableView: UITableView) -> Int { diff --git a/pass/Controllers/PasswordEditorTableViewController.swift b/pass/Controllers/PasswordEditorTableViewController.swift index afa1773..334546a 100644 --- a/pass/Controllers/PasswordEditorTableViewController.swift +++ b/pass/Controllers/PasswordEditorTableViewController.swift @@ -46,7 +46,10 @@ class PasswordEditorTableViewController: UITableViewController, FillPasswordTabl override func viewDidLoad() { super.viewDidLoad() - navigationItem.title = navigationItemTitle + if navigationItemTitle != nil { + navigationItem.title = navigationItemTitle + } + tableView.register(UINib(nibName: "TextFieldTableViewCell", bundle: nil), forCellReuseIdentifier: "textFieldCell") tableView.register(UINib(nibName: "TextViewTableViewCell", bundle: nil), forCellReuseIdentifier: "textViewCell") tableView.register(UINib(nibName: "FillPasswordTableViewCell", bundle: nil), forCellReuseIdentifier: "fillPasswordCell")