def METHOD_NAME(self, organization_data):
    organization = (
        self.db.query(models.Organization)
        .filter_by(pubid=organization_data["pubid"])
        .one_or_none()
    )
    if not organization:
        organization = models.Organization()
        self.db.add(organization)
    self.setattrs(organization, organization_data)