Changeset - ca3ebd5c3c42
[Not reviewed]
0 1 0
HanzZ - 14 years ago 2011-06-19 20:01:23
hanzz.k@gmail.com
Fixed VCard without to attribute
1 file changed with 2 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/vcardresponder.cpp
Show inline comments
 
@@ -63,13 +63,14 @@ bool VCardResponder::handleGetRequest(const Swift::JID& from, const Swift::JID&
 
	}
 

	
 
	Swift::JID to_ = to;
 

	
 
	std::string name = to_.getUnescapedNode();
 
	if (name.empty()) {
 
		to_ = user->getComponent()->getJID();
 
		std::cout << "aaaa " << user->getComponent()->getJID().toString() << "\n";
 
		to_ = user->getJID();
 
		name = to_.getUnescapedNode();
 
	}
 

	
 
	if (name.find_last_of("%") != std::string::npos) {
 
		name.replace(name.find_last_of("%"), 1, "@");
 
	}
0 comments (0 inline, 0 general)