migrateFromSPToHive method
Implementation
Future<void> migrateFromSPToHive() async {
if (_config.type != StorageType.hive) {
throw StateError('Current storage type is not Hive');
}
final tempPrefs = await SharedPreferences.getInstance();
final keys = tempPrefs.getKeys();
for (final key in keys) {
final value = tempPrefs.get(key);
if (value != null) {
await _hiveBox!.put(key, value);
}
}
}