Trim values for toBoolean