[Groonga-commit] groonga/grnci at 394d4b6 [master] Fix a bug that --key of delete is JSON-encoded.

Zurück zum Archiv-Index

Susumu Yata null+****@clear*****
Mon Sep 11 16:42:52 JST 2017


Susumu Yata	2017-09-11 16:42:52 +0900 (Mon, 11 Sep 2017)

  New Revision: 394d4b6bd4923820d6bdda24aa11c08154b58895
  https://github.com/groonga/grnci/commit/394d4b6bd4923820d6bdda24aa11c08154b58895

  Message:
    Fix a bug that --key of delete is JSON-encoded.

  Modified files:
    v2/command.go

  Modified: v2/command.go (+1 -6)
===================================================================
--- v2/command.go    2017-09-11 16:23:28 +0900 (2b09a18)
+++ v2/command.go    2017-09-11 16:42:52 +0900 (6499a17)
@@ -118,11 +118,6 @@ func formatParamMatchColumns(key string, value interface{}) (string, error) {
 	return formatParamDelim(key, value, "||")
 }
 
-// formatParamJSON returns the JSON-encoded value (delete --key).
-func formatParamJSON(key string, value interface{}) (string, error) {
-	return EncodeJSON(value), nil
-}
-
 type paramFormat struct {
 	key      string      // Parameter key
 	format   formatParam // Custom function to format a parameter.
@@ -333,7 +328,7 @@ var commandFormats = map[string]*commandFormat{
 	"delete": newCommandFormat(
 		nil,
 		newParamFormat("table", nil, true),
-		newParamFormat("key", formatParamJSON, false),
+		newParamFormat("key", nil, false),
 		newParamFormat("id", nil, false),
 		newParamFormat("filter", nil, false),
 	),
-------------- next part --------------
HTML����������������������������...
URL: https://lists.osdn.me/mailman/archives/groonga-commit/attachments/20170911/0780e2e2/attachment.htm 



More information about the Groonga-commit mailing list
Zurück zum Archiv-Index