Fixed a logic error when validating the config

Thanks to colleague Chris Whealy for providing the fix (I encountered
the error, but didn't get a chance to fix it).