static bool? boolFromInt(int? value) { try { return value != null && value == 1 ? true : false; } on Exception catch (e) { return false; } }