diff --git a/domain-server/src/DomainServer.cpp b/domain-server/src/DomainServer.cpp index 653f0e84cd..b4243ef8a0 100644 --- a/domain-server/src/DomainServer.cpp +++ b/domain-server/src/DomainServer.cpp @@ -1837,10 +1837,10 @@ void DomainServer::processNodeDisconnectRequestPacket(QSharedPointer p // we want to check what type this node was before going to kill it so that we can avoid sending the RemovedNode // packet to nodes that don't care about this type - auto node = limitedNodeList->nodeWithUUID(nodeUUID); + auto nodeToKill = limitedNodeList->nodeWithUUID(nodeUUID); - if (node) { - auto nodeType = node->getType(); + if (nodeToKill) { + auto nodeType = nodeToKill->getType(); limitedNodeList->killNodeWithUUID(nodeUUID); static auto removedNodePacket = NLPacket::create(PacketType::DomainServerRemovedNode, NUM_BYTES_RFC4122_UUID);