anchor.diff:      case maps:find(PktId, AwaitingComp) of
           {ok, TRef} ->
               cancel_timer(TRef),
  -            {noreply, Session#session{awaiting_comp = maps:remove(PktId, AwaitingComp)}};
  +            noreply(Session#session{awaiting_comp = maps:remove(PktId, AwaitingComp)});
           error ->
               lager:error("Session ~s cannot find PUBCOMP: PktId=~p", [ClientId, PktId]),
  -            {noreply, Session}
  +            noreply(Session)
       end;
   
   handle_cast(Msg, State) ->
  
positive.code:             cancel_timer(TRef),
              TRef1 = timer(Timeout, {timeout, awaiting_comp, PktId}),
              Session1 = acked(PktId, Session#session{awaiting_comp = maps:put(PktId, TRef1, AwaitingComp)}),
              {noreply, dequeue(Session1)};
          error ->
              lager:error("Session ~s cannot find PUBREC '~p'!", [ClientId, PktId]),
              {noreply, Session}
      end;
  
  %% PUBREL
  
negative.code:     lager:info("Session ~s unlink with client ~p: reason=~p",
                      [ClientId, ClientPid, Reason]),
      TRef = timer(Expires, session_expired),
      noreply(Session#session{client_pid = undefined, expired_timer = TRef});
  
  handle_info({'EXIT', Pid, _Reason}, Session = #session{client_id = ClientId,
                                                         client_pid = ClientPid}) ->
                                                              
      lager:error("Session ~s received unexpected EXIT:"
                      " client_pid=~p, exit_pid=~p", [ClientId, ClientPid, Pid]),
  