public static void RemovePendingMessage(this ClientSession session, PendingMessage pending) { lock (pendingMessagesLock) { session.PendingMessages.Remove(pending); } }
public static void AddPendingMessage(this ClientSession session, PendingMessage pending) { lock (pendingMessagesLock) { session.PendingMessages.Add(pending); } }