From 8235b6efc97d198fee5354f3db79424d7963339b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Renault?= Date: Thu, 21 Feb 2019 20:14:08 +0100 Subject: [PATCH] fix: Do not error when an attribute is registered for ranking --- src/rank/criterion/sort_by_attr.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rank/criterion/sort_by_attr.rs b/src/rank/criterion/sort_by_attr.rs index 15bd09ee5..05033a1e1 100644 --- a/src/rank/criterion/sort_by_attr.rs +++ b/src/rank/criterion/sort_by_attr.rs @@ -78,7 +78,7 @@ impl<'a> SortByAttr<'a> { None => return Err(SortByAttrError::AttributeNotFound), }; - if schema.props(attr).is_ranked() { + if !schema.props(attr).is_ranked() { return Err(SortByAttrError::AttributeNotRegisteredForRanking); }