toBool function

bool toBool(
  1. dynamic value
)

Implementation

bool toBool(dynamic value) {
  if (value == 1 || value == true || value == "true") {
    return true;
  }
  return false;
}