PragmaTwice commented on code in PR #2017:
URL: https://github.com/apache/kvrocks/pull/2017#discussion_r1452125980


##########
src/server/redis_connection.cc:
##########
@@ -130,6 +130,39 @@ void Connection::Reply(const std::string &msg) {
   redis::Reply(bufferevent_get_output(bev_), msg);
 }
 
+std::string Connection::Bool(bool b) const {
+  if (protocol_version_ == RESP::v3) {
+    return b ? "#t" CRLF : "#f" CRLF;
+  }
+  return Integer(b ? 1 : 0);
+}
+
+std::string Connection::MultiBulkString(const std::vector<std::string> &values,
+                                        bool output_nil_for_empty_string) 
const {

Review Comment:
   Ahh I see it is used in Array2RESP. But if it is just used here maybe we can 
remove it.



##########
src/server/redis_connection.cc:
##########
@@ -130,6 +130,39 @@ void Connection::Reply(const std::string &msg) {
   redis::Reply(bufferevent_get_output(bev_), msg);
 }
 
+std::string Connection::Bool(bool b) const {
+  if (protocol_version_ == RESP::v3) {
+    return b ? "#t" CRLF : "#f" CRLF;
+  }
+  return Integer(b ? 1 : 0);
+}
+
+std::string Connection::MultiBulkString(const std::vector<std::string> &values,
+                                        bool output_nil_for_empty_string) 
const {

Review Comment:
   Ahh I see it is used in Array2RESP. But if it is just used here maybe we can 
remove it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to