Handle blank values
Return 0 instead of 1, added braces
Merge pull request #114 from benrwb/patch-1

Handle blank values