From dd043f8226e04e46ccbff2b8c2396079d222e632 Mon Sep 17 00:00:00 2001
From: Michael Nitschinger <michael@nitschinger.at>
Date: Mon, 4 Jul 2016 07:55:12 +0200
Subject: [PATCH] Revert "logical error in decode()"

This needs to be reverted because it breaks all the other codepaths since it
just doesn't return anything on read or scan.

This reverts commit 44660de713b5b805ba4b8a07b12faf60aaef163d.
---
 .../java/com/yahoo/ycsb/db/couchbase2/Couchbase2Client.java     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/couchbase2/src/main/java/com/yahoo/ycsb/db/couchbase2/Couchbase2Client.java b/couchbase2/src/main/java/com/yahoo/ycsb/db/couchbase2/Couchbase2Client.java
index dc600011..78334667 100644
--- a/couchbase2/src/main/java/com/yahoo/ycsb/db/couchbase2/Couchbase2Client.java
+++ b/couchbase2/src/main/java/com/yahoo/ycsb/db/couchbase2/Couchbase2Client.java
@@ -856,7 +856,7 @@ public class Couchbase2Client extends DB {
       for (Iterator<Map.Entry<String, JsonNode>> jsonFields = json.fields(); jsonFields.hasNext();) {
         Map.Entry<String, JsonNode> jsonField = jsonFields.next();
         String name = jsonField.getKey();
-        if (!(checkFields && fields.contains(name))) {
+        if (checkFields && fields.contains(name)) {
           continue;
         }
         JsonNode jsonValue = jsonField.getValue();
-- 
GitLab