Fix issues with OTP notification (#517)

* Use "Beta" since this is what Apple uses too
* Actually copy the OTP if the option is set
* Shorten notification text to make it fit to smaller screens
* Set notification center delegate before app launches
* Fix SwiftFormat issue fixed with version 0.48.12
This commit is contained in:
Danny Mösch 2021-10-04 02:20:22 +02:00 committed by GitHub
parent 32b7c9b635
commit 3eea063d61
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 11 additions and 10 deletions

View file

@ -99,7 +99,6 @@ class PasswordNavigationViewController: UIViewController {
options: []
)
notificationCenter.setNotificationCategories([otpCategory])
notificationCenter.delegate = NotificationCenterDispatcher.shared
}
override func viewWillAppear(_ animated: Bool) {

View file

@ -225,7 +225,7 @@ class SettingsTableViewController: UITableViewController, UITabBarControllerDele
@objc
func alertTextFieldDidChange(_ sender: UITextField) {
// check whether we should enable the Save button in setPasscodeLockAlert
if let setPasscodeLockAlert = self.setPasscodeLockAlert,
if let setPasscodeLockAlert = setPasscodeLockAlert,
let setPasscodeLockAlertTextFields0 = setPasscodeLockAlert.textFields?[0],
let setPasscodeLockAlertTextFields1 = setPasscodeLockAlert.textFields?[1] {
if sender == setPasscodeLockAlertTextFields0 || sender == setPasscodeLockAlertTextFields1 {