getByPath method Null safety

BackupModel? getByPath(
  1. String path
)

Gets a BackupModel registry by its path.

Implementation

BackupModel? getByPath(String path) {
  List<BackupModel> bkups = _select(whereStmt: "WHERE $columnPath = '$path'");
  return bkups.isNotEmpty ? bkups.first : null;
}