Refactored complete-, and progressTask methods.