From f9550cc6b67eb0d9e4d62dae1a31833eba948c60 Mon Sep 17 00:00:00 2001 From: sahankj2000 Date: Mon, 22 Jul 2024 16:43:23 +0530 Subject: [PATCH] changing to a better check --- .../dataapi/opdispensers/DataApiDeleteOneOpDispenser.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/nb-adapters/adapter-dataapi/src/main/java/io/nosqlbench/adapter/dataapi/opdispensers/DataApiDeleteOneOpDispenser.java b/nb-adapters/adapter-dataapi/src/main/java/io/nosqlbench/adapter/dataapi/opdispensers/DataApiDeleteOneOpDispenser.java index c920c8256..7af86c603 100644 --- a/nb-adapters/adapter-dataapi/src/main/java/io/nosqlbench/adapter/dataapi/opdispensers/DataApiDeleteOneOpDispenser.java +++ b/nb-adapters/adapter-dataapi/src/main/java/io/nosqlbench/adapter/dataapi/opdispensers/DataApiDeleteOneOpDispenser.java @@ -66,9 +66,8 @@ public class DataApiDeleteOneOpDispenser extends DataApiOpDispenser { } private float[] getVectorFromOp(ParsedOp op, long l) { - Object rawVectorObject = op.get("vector", l); - if (rawVectorObject != null) { - return getVectorValues(rawVectorObject); + if (op.isDefined("vector")) { + return getVectorValues(op.get("vector", l)); } return null; }