def update(policy_id, **kwargs):
    """
    Updates a policy.
    :param policy_id:
    :param kwargs:
    :return:
    """
    policy = get(policy_id)

    for key, value in kwargs.items():
        setattr(policy, key, value)

    return database.update(policy)

    Updates a policy.
    :param policy_id:
    :param kwargs:
    :return:
    
lemur/policies/service.py