connectivity/com.nokia.carbide.remoteConnections/src/com/nokia/carbide/remoteconnections/internal/registry/Registry.java
changeset 666 4817219999f0
parent 382 6a8fd4465a9b
child 687 593d05f9d5ca
--- a/connectivity/com.nokia.carbide.remoteConnections/src/com/nokia/carbide/remoteconnections/internal/registry/Registry.java	Wed Dec 09 15:40:36 2009 -0600
+++ b/connectivity/com.nokia.carbide.remoteConnections/src/com/nokia/carbide/remoteconnections/internal/registry/Registry.java	Wed Dec 09 15:43:55 2009 -0600
@@ -131,6 +131,7 @@
 		return true;
 	}
 	
+	@SuppressWarnings("unchecked")
 	private <T> void loadExtensions(String extensionId, String loadError, Collection<T> extensionObjects, IFilter filter) {
 		IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
 		IExtensionPoint extensionPoint = extensionRegistry.getExtensionPoint(extensionId);
@@ -235,7 +236,8 @@
 		List<IConnectedService> connectedServices = new ArrayList<IConnectedService>();
 		for (IService service : getCompatibleServices(connection.getConnectionType())) {
 			IConnectedService connectedService = createConnectedService(service, connection);
-			connectedServices.add(connectedService);
+			if (connectedService != null)
+				connectedServices.add(connectedService);
 		}
 		return connectedServices;
 	}
@@ -305,7 +307,7 @@
 		Collection<IService> services = connectionTypeToServices.get(connectionType);
 		if (services != null)
 			return new ArrayList<IService>(services);
-		return Collections.EMPTY_LIST;
+		return Collections.emptyList();
 	}
 	
 	/* (non-Javadoc)