express-query-boolean
express-query-boolean copied to clipboard
Added support for upper case values parse
Hey,
It'd be cool if your lib parse the string value to lower case during the comparison because people can send TRUE or FALSE values or even True or False. I thought about saving the .toLowerCase() value in another variable to reuse but I guess it wouldn't be worth creating another var just to reuse in two lines. I also thought about converting 0 and 1 (both string and number) to bool, but I understand that the package will not have control on where it should parse it or not (the user may actually need it as a numeric value instead of bool), so I leave it untouched.
Thanks!