From 4bfcf4654a3ea3253dcce8ef6a8d290f1d6dce72 Mon Sep 17 00:00:00 2001 From: avimredis <64842313+avimredis@users.noreply.github.com> Date: Mon, 26 Apr 2021 21:11:38 +0300 Subject: [PATCH] Fix error reply of GEOSEARCHSTORE unsupported args (#8865) When [WITHCOORD] [WITHDIST] [WITHHASH] are used, the error mentioned GEORADIUS command --- src/geo.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/geo.c b/src/geo.c index 7c75738a2..c53df794e 100644 --- a/src/geo.c +++ b/src/geo.c @@ -651,9 +651,9 @@ void georadiusGeneric(client *c, int srcKeyIndex, int flags) { /* Trap options not compatible with STORE and STOREDIST. */ if (storekey && (withdist || withhash || withcoords)) { - addReplyError(c, - "STORE option in GEORADIUS is not compatible with " - "WITHDIST, WITHHASH and WITHCOORDS options"); + addReplyErrorFormat(c, + "%s is not compatible with WITHDIST, WITHHASH and WITHCOORD options", + flags & GEOSEARCHSTORE? "GEOSEARCHSTORE": "STORE option in GEORADIUS"); return; }