read method
Reads value associated with key from storage.
Implementation
@override
dynamic read(String key) {
// Duck-typing support for shared_preferences getString.
// ignore: avoid_dynamic_calls
final dynamic value = _prefs.getString(_prefixedKey(key));
if (value == null || value is! String) return null;
return jsonDecode(value);
}