check for nil value