load method

Implementation

Future<DVSchemaEvolution?> load(String id) async {
  await _prepare();
  final List<Map<String, Object?>> rows = await database.query(
    'SELECT state FROM $_table WHERE id = ?',
    <Object?>[id],
  );
  if (rows.isEmpty) return null;
  return DVSchemaEvolution.fromJson(
    jsonDecode('${rows.single['state']}') as Map<String, Object?>,
  );
}