checkNullableInt static method
Implementation
static int? checkNullableInt(dynamic value, String fieldName) {
if (value == null) return null;
if (value is int) return value;
throw FormatException("Invalid type for '$fieldName': expected int");
}