Raise a more useful exception when nil value is provided