TOPasscodeViewController
TOPasscodeViewController copied to clipboard
Clear passcode to simplify controller re-use
- [x] I have read this issue template and provided all possible information.
- [x] I'm using CocoaPods and have run
pod updatebefore filing this issue.
Hardware / Software
Which version of the library were you using? 0.0.2 Which version of iOS are you running? 11.3 (simulator) What model of iOS device were you testing on? iPad Pro 10.5 (simulator) If using CocoaPods, which version of CocoaPods are you on? 1.5.3
Feature request
I would like to avoid creating a new instance of TOPasscodeViewController every time I want to present one. Instead, I'd like to re-use an instance that's created and owned by the presenting controller.
I can accomplish this now, but the second time I present the passcode TOPasscodeViewController, it still has its dots filled in from the previous entry.
It seems like there are two ways to solve this:
- Automatically clear the entered passcode when
passcodeViewController(_:isCorrectCode:)returns a success. - Expose an additional method on
TOPasscodeViewController– something likeclearPasscode().