anchor.diff:  				case mnesia:read(subscriber, Subscriber, write) of
   					[#subscriber{balance = Balance, disconnect = Flag,
   								session_attributes = SessionList} = Entry] ->
  -						NewSessionList = remove_session(SessionList, AcctSessionID, Nas,
  -								Subscriber, Attributes),
   						NewBalance = Balance - Usage,
  -						NewEntry = Entry#subscriber{balance = NewBalance,
  -								session_attributes = NewSessionList},
  +						NewEntry = case remove_session(SessionList, AcctSessionID, Nas,
  +								Subscriber, Attributes) of
  +							{ok, NewSessionList} ->
  +								Entry#subscriber{balance = NewBalance,
  +										session_attributes = NewSessionList};
  +							{error, SessionList} ->
  +								Entry#subscriber{balance = NewBalance,
  +										session_attributes = SessionList}
  +						end,
   						mnesia:write(subscriber, NewEntry, write),
   						{NewBalance, Flag};
   					[] ->
  
positive.code: 		end.
  
  -spec remove_session(SessionList, AcctSessionID, Nas, Subscriber, Attributes) ->
  		NewSessionList
  	when
  		SessionList :: [radius_attributes:attributes()],
  		AcctSessionID :: integer(),
  		Nas :: string() | inet:ip_address(),
  		Subscriber :: string() | binary(),
  		Attributes :: radius_attributes:attributes(),
  		NewSessionList :: [] | [radius_attributes:attributes()].
  %% @doc From `SessionList' remove a session which includes `Attributes'
  %% and return rest of the `SessionList'.
  %% @hidden
  remove_session(SessionList, AcctSessionID, Nas, Subscriber, Attributes) ->
  	try
  
negative.code: 							end
  				end;
  			(_, []) ->
  				throw(session_not_found)
  		end,
  		{ok, F(F, SessionList)}
  	catch
  		_: Reason ->
  			error_logger:error_report(["Failed to remove current session from subscriber",
  					{error, Reason}, {subscriber, Subscriber}, {session, AcctSessionID},
  					{nas, Nas}, {attributes, Attributes}]),
  			{error, SessionList}
  	end.
  
  -spec extract_session_attributes(Attributes) -> SessionAttributes
  