JAVA-381: Partially reverted last change. The synchronization does have to be outside the null check, otherwise it's a race condition and the notification may never be received
JAVA-381: Partially reverted last change. The synchronization does have to be outside the null check, otherwise it's a race condition and the notification may never be received

jyemin/mongo-java-driver,jyemin/mongo-java-driver,PSCGroup/mongo-java-driver,gianpaj/mongo-java-driver,jsonking/mongo-java-driver,davydotcom/mongo-java-driver,rozza/mongo-java-driver,wanggc/mongo-java-driver,wanggc/mongo-java-driver,davydotcom/mongo-java-driver,kay-kim/mongo-java-driver,jsonking/mongo-java-driver,rozza/mongo-java-driver