ifTrue<T> static method
Returns a value if condition is true, otherwise returns null
Example:
Helpers.ifTrue(condition, () => 'value');
Implementation
static T? ifTrue<T>(bool condition, T Function() value) {
return condition ? value() : null;
}