diff --git a/apps/iot/src/http_handler/http_host_handler.erl b/apps/iot/src/http_handler/http_host_handler.erl index 95779b6..74f99bf 100644 --- a/apps/iot/src/http_handler/http_host_handler.erl +++ b/apps/iot/src/http_handler/http_host_handler.erl @@ -78,7 +78,10 @@ handle_request("POST", "/host/publish_command", _, <<"ts">> => iot_util:current_time(), <<"m">> => iolist_to_binary(jiffy:encode(Params, [force_utf8])) }, - BinReply = iolist_to_binary(jiffy:encode(append_service_name(PostParams, Reply), [force_utf8])), + + Reply1 = append_service_name(PostParams, Reply), + lager:debug("[http_host_handler] publish message is: ~p", [Reply1]), + BinReply = iolist_to_binary(jiffy:encode(Reply1, [force_utf8])), case iot_host:aes_encode(Pid, CommandType, BinReply) of {error, Reason} when is_binary(Reason) ->