toBool method

bool toBool()

Converts a case-insensitive string of 'true' to a boolean. Returns false if the string is null, empty, or not 'true'.

Implementation

bool toBool() => this?.toLowerCase() == 'true';