flutter_secure_storage
flutter_secure_storage copied to clipboard
resetOnError returns String
The method in question is main method of this package and that's String? read(String key)
.
You use it, you save and read keys, you code your app around the premise that it returns string when it has saved entry with associated key.
But then, this fix for resetOnError: true
will return plain string for this method Data has been reset
which is very unexpected. Obviously rest of the app thinks that string is result for the saved key, because that's how the method read
is supposed to work.
Proposition:
- Log the issue and return null