Added a boolean parsing function