diff --git a/src/emqx_ws_connection.erl b/src/emqx_ws_connection.erl index c54cfefb9..47239efe9 100644 --- a/src/emqx_ws_connection.erl +++ b/src/emqx_ws_connection.erl @@ -532,7 +532,7 @@ handle_outgoing(Packets, State = #state{active_n = ActiveN, mqtt_piggyback = MQT end, {case MQTTPiggyback of - single -> {binary, IoData}; + single -> [{binary, IoData}]; multiple -> lists:map(fun(Bin) -> {binary, Bin} end, IoData) end, ensure_stats_timer(NState)}.