We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
and
The and helper returns the value as it is if its falsy (rather than converting it to a boolean first) here: https://github.com/jmurphyau/ember-truth-helpers/blob/master/packages/ember-truth-helpers/src/helpers/and.ts#L33
This results in some unexpected behavior, see twiddle
Can we change that line to:
return truthConvert(params[i]);
or
return !!params[i];
So that and returns false rather than undefined when it gets undefined. That would result in a more expected behavior IMO.
false
undefined
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The
and
helper returns the value as it is if its falsy (rather than converting it to a boolean first) here: https://github.com/jmurphyau/ember-truth-helpers/blob/master/packages/ember-truth-helpers/src/helpers/and.ts#L33This results in some unexpected behavior, see twiddle
Suggestion
Can we change that line to:
or
So that
and
returnsfalse
rather thanundefined
when it getsundefined
. That would result in a more expected behavior IMO.The text was updated successfully, but these errors were encountered: