Test whether completed exists before trying to check its value