put method
Save to local storage
Implementation
@override
/// Save to local storage
Future<void> put(String key, dynamic value) async {
final path = await _storagePath;
final file = File(_keyPath(path, key));
String dataToStore = value.toString();
if (mode == EncryptionMode.fernet && encryptionKey != null) {
dataToStore = fernet.encryptFernet(dataToStore, encryptionKey!);
} else if (mode == EncryptionMode.aes && encryptionKey != null) {
dataToStore = aes.encryptAES(dataToStore, encryptionKey!);
}
await file.writeAsString(dataToStore);
}