From 9aa8a0f255ef8be854c066c48d2b87586c282cfe Mon Sep 17 00:00:00 2001 From: lxf Date: Mon, 16 Jul 2018 18:36:52 +0800 Subject: [PATCH] sort did result --- src/lib/explorer/extensions/commands/getdid.cpp | 1 + test/test-rpc-v3/utils/mvs_rpc.py | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/explorer/extensions/commands/getdid.cpp b/src/lib/explorer/extensions/commands/getdid.cpp index 4e7c40367..1d6919643 100644 --- a/src/lib/explorer/extensions/commands/getdid.cpp +++ b/src/lib/explorer/extensions/commands/getdid.cpp @@ -41,6 +41,7 @@ console_result getdid::invoke (Json::Value& jv_output, auto sh_vec = blockchain.get_registered_dids(); + std::sort(sh_vec->begin(), sh_vec->end()); // add blockchain dids for (auto& elem : *sh_vec) { json_value.append(elem.get_symbol()); diff --git a/test/test-rpc-v3/utils/mvs_rpc.py b/test/test-rpc-v3/utils/mvs_rpc.py index f1dc19793..9341a5ef5 100644 --- a/test/test-rpc-v3/utils/mvs_rpc.py +++ b/test/test-rpc-v3/utils/mvs_rpc.py @@ -692,7 +692,8 @@ def ban_node(peer): @mvs_api def register_mit(account, password, to_did, symbol=None, content=None, mits=None, fee=None): - + if None == content: + content = "" ''' account Account name required. password Account password(authorization) required.