fix backwards logic in exception message.