Optimize DefaultPicoContainer for test. (Fix test)

This commit is contained in:
Sergey Evdokimov
2011-11-25 20:10:22 +03:00
parent 2bc10e6be9
commit 84916b9c3f
@@ -352,7 +352,7 @@ public class DefaultPicoContainer implements MutablePicoContainer, Serializable
private final ConcurrentHashMap<T, T> concurrentSet = new ConcurrentHashMap<T, T>();
public boolean contains(@Nullable T element) {
return element != null || concurrentSet.containsKey(element);
return element != null && concurrentSet.containsKey(element);
}
public void add(@NotNull T element) {