Update command adding fail safe if field is not present and added test classes.