def METHOD_NAME(service, oldImageID, newImageID):
    if service["ImageID"] == oldImageID:
        service["ImageID"] = newImageID
    for svc in service["Services"]:
        METHOD_NAME(svc, oldImageID, newImageID)