def _validate_no_rels(param, rels):
    if param.field in rels:
        raise InvalidQueryParams(**{
            'detail': 'The sort query param value of "%s" is not '
                      'supported. Sorting on relationships is not '
                      'currently supported' % param.raw_field,
            'links': LINK,
            'parameter': PARAM,
        })