+ // recheck if there exists a buffer to store a redirected message in
+ for(int i = 0; i < redirectedMessages.count(); i++) {
+ const RawMessage &rawMsg = _messageQueue.at(i);
+ if(bufferInfoCache.contains(rawMsg.networkId) && bufferInfoCache[rawMsg.networkId].contains(rawMsg.target)) {
+ bufferInfo = bufferInfoCache[rawMsg.networkId][rawMsg.target];
+ } else {
+ // no luck -> we store them in the StatusBuffer
+ bufferInfo = Core::bufferInfo(user(), rawMsg.networkId, BufferInfo::StatusBuffer, "");
+ // add the StatusBuffer to the Cache in case there are more Messages for the original target
+ bufferInfoCache[rawMsg.networkId][rawMsg.target] = bufferInfo;
+ }