Skip to content
Permalink
Browse files

value: fix chain null check

  • Loading branch information...
aberaud committed Mar 10, 2019
1 parent fec5a6e commit 57ea09808e0d81659f1f9458171ca5b81a05b872
Showing with 3 additions and 3 deletions.
  1. +3 −3 include/opendht/value.h
@@ -165,8 +165,8 @@ struct OPENDHT_PUBLIC Value
return chainOr(std::move(f1), std::move(f2));
}
static Filter chain(Filter&& f1, Filter&& f2) {
if (not f1) return std::move(f1);
if (not f2) return std::move(f2);
if (not f1) return std::move(f2);
if (not f2) return std::move(f1);
return [f1,f2](const Value& v) {
return f1(v) and f2(v);
};
@@ -874,7 +874,7 @@ struct OPENDHT_PUBLIC Query
{
static const std::string QUERY_PARSE_ERROR;

Query(Select s = {}, Where w = {}, bool none = false) : select(s), where(w), none(none) { };
Query(Select s = {}, Where w = {}, bool none = false) : select(std::move(s)), where(std::move(w)), none(none) { };

/**
* Initializes a query based on a SQL-ish formatted string. The abstract

0 comments on commit 57ea098

Please sign in to comment.
You can’t perform that action at this time.