MDL-37524 - improve check for completion