Elffuss BraidHub

kikocis/java-driver public

Add null check before removing ks from token map (JAVA-543).
Changesetb73911181d2e2caa8d6f0273669cdad22daec8776f8db5e2e8c0fc5e368b0e93
Authorolim7t <omichallat+github@gmail.com> · 2014-12-16 17:53 +01:00
Committerolim7t <omichallat+github@gmail.com> · 2014-12-16 17:53 +01:00
Parents64b437e82b4d

Browse the files at this changeset

1 file changed

modified driver-core/src/main/java/com/datastax/driver/core/Metadata.java +2 −1
@@ -300,7 +300,8 @@
300300
301301 void removeKeyspace(String keyspace) {
302302 keyspaces.remove(keyspace);
303- tokenMap.tokenToHosts.remove(keyspace);
303+ if (tokenMap != null)
304+ tokenMap.tokenToHosts.remove(keyspace);
304305 }
305306
306307 /**