intFromModel function

int intFromModel(
  1. Model model
)

Creates an int from a Model. If unsucessful, will return -1.

Implementation

int intFromModel(Model model) => model.data["data"]?.toInt() ?? -1;