summaryrefslogtreecommitdiff
path: root/src/mod_mqtt_session.erl
diff options
context:
space:
mode:
authorEvgeny Khramtsov <ekhramtsov@process-one.net>2019-06-24 20:32:34 +0300
committerEvgeny Khramtsov <ekhramtsov@process-one.net>2019-06-24 20:32:34 +0300
commita3e0cbbdd8a3ec4bbfa17e5147c59978021fc0b5 (patch)
tree6a00378671ffaee338317c403b46b6a5ecad5ce1 /src/mod_mqtt_session.erl
parentCheck if mod_last is loaded before calling its functions (diff)
Make logging messages more consistent
Diffstat (limited to 'src/mod_mqtt_session.erl')
-rw-r--r--src/mod_mqtt_session.erl10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mod_mqtt_session.erl b/src/mod_mqtt_session.erl
index db9a632c..f886bc3f 100644
--- a/src/mod_mqtt_session.erl
+++ b/src/mod_mqtt_session.erl
@@ -186,7 +186,7 @@ handle_call({get_state, Pid}, From, State) ->
noreply(State3)
end;
handle_call(Request, From, State) ->
- ?WARNING_MSG("Got unexpected call from ~p: ~p", [From, Request]),
+ ?WARNING_MSG("Unexpected call from ~p: ~p", [From, Request]),
noreply(State).
handle_cast(accept, #state{socket = {_, Sock}} = State) ->
@@ -204,7 +204,7 @@ handle_cast(accept, #state{socket = {_, Sock}} = State) ->
stop(State, {socket, Why})
end;
handle_cast(Msg, State) ->
- ?WARNING_MSG("Got unexpected cast: ~p", [Msg]),
+ ?WARNING_MSG("Unexpected cast: ~p", [Msg]),
noreply(State).
handle_info(Msg, #state{stop_reason = {resumed, Pid} = Reason} = State) ->
@@ -275,7 +275,7 @@ handle_info({Ref, badarg}, State) when is_reference(Ref) ->
%% TODO: figure out from where this messages comes from
noreply(State);
handle_info(Info, State) ->
- ?WARNING_MSG("Got unexpected info: ~p", [Info]),
+ ?WARNING_MSG("Unexpected info: ~p", [Info]),
noreply(State).
-spec handle_packet(mqtt_packet(), state()) -> {ok, state()} |
@@ -308,7 +308,7 @@ handle_packet(#pubrec{id = ID, code = Code}, State) ->
{ok, State};
false ->
Code1 = 'packet-identifier-not-found',
- ?DEBUG("Got unexpected PUBREC with id=~B, "
+ ?DEBUG("Unexpected PUBREC with id=~B, "
"sending PUBREL with error code '~s'", [ID, Code1]),
send(State, #pubrel{id = ID, code = Code1})
end;
@@ -324,7 +324,7 @@ handle_packet(#pubrel{id = ID}, State) ->
send(State#state{acks = Acks}, #pubcomp{id = ID});
error ->
Code = 'packet-identifier-not-found',
- ?DEBUG("Got unexpected PUBREL with id=~B, "
+ ?DEBUG("Unexpected PUBREL with id=~B, "
"sending PUBCOMP with error code '~s'", [ID, Code]),
Pubcomp = #pubcomp{id = ID, code = Code},
send(State, Pubcomp)