return $status && 1; # canonize false, leave true as-is
That would be great except it doesn't canonize false. It returns $status if $status is false. So, for example, if $status is "" it will return "", not 0.
-sauoq "My two cents aren't worth a dime.";
In reply to Re: another variation (variable set to 0 ? 0 : 1)
by sauoq
in thread variable set to 0 ? 0 : 1
by c
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |