write method
Writes value associated with key to storage.
Implementation
@override
FutureOr<void> write(String key, dynamic value) async {
_cache[key] = value;
final String encoded = jsonEncode(value);
await _secureStorage.write(key: key, value: encoded);
}