improve check for zero results