Fixing error handling conditional.