Unverified Commit fb100cf0 authored by Dave Cridland's avatar Dave Cridland Committed by GitHub

Merge pull request #1043 from guusdk/OF-1508_Entity-Caps-no-null-lookups

OF-1508: Prevent empty entity caps hash lookups.
parents fada075d 95ed5680
......@@ -315,13 +315,16 @@ public class EntityCapabilitiesManager implements IQResultListener, UserEventLis
/**
* Returns the entity capabilities for a specific JID. The specified JID
* should be a full JID that identitied the entity's connection.
* should be a full JID that identified the entity's connection.
*
* @param jid the full JID of entity
* @return the entity capabilities of jid.
* @return the entity capabilities of jid, or null if these are unavailable.
*/
public EntityCapabilities getEntityCapabilities(JID jid) {
String verAttribute = entityCapabilitiesUserMap.get(jid);
if ( verAttribute == null ) {
return null;
}
return entityCapabilitiesMap.get(verAttribute);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment