def upgrade_role_restrictions_6_0_to_6_1(roles_meta, _new_role_restrictions):
    for role_name, role_definition in six.iteritems(roles_meta):
        if role_name in _new_role_restrictions:
            role_definition['restrictions'] = _new_role_restrictions[role_name]

    return roles_meta
dataset/ETHPy150Open openstack/fuel-web/nailgun/nailgun/utils/migration.py/upgrade_role_restrictions_6_0_to_6_1/original