This commit is contained in:
anlicheng 2023-08-17 16:12:09 +08:00
parent d6d3b9d718
commit 85214a89c9

View File

@ -261,7 +261,7 @@ handle_event({call, From}, {create_session, PubKey}, ?STATE_DENIED, State = #sta
EncReply = iot_cipher_rsa:encode(Reply, PubKey),
{keep_state, State, [{reply, From, {ok, <<10:8, EncReply/binary>>}}]};
handle_event({call, From}, {create_session, PubKey}, StateName, State = #state{host_id = HostId, uuid = UUID, aes = Aes}) ->
handle_event({call, From}, {create_session, PubKey}, StateName, State = #state{uuid = UUID, aes = Aes}) ->
Reply = #{<<"a">> => true, <<"aes">> => Aes},
EncReply = iot_cipher_rsa:encode(Reply, PubKey),
{ok, AffectedRow} = host_bo:change_status(UUID, ?HOST_ONLINE),