corrected checks for default value, thanks Ross
closes #464