Skip to content
This repository has been archived by the owner on Apr 23, 2020. It is now read-only.

Commit

Permalink
usState.getUs() might return null
Browse files Browse the repository at this point in the history
  • Loading branch information
Randgalt committed Feb 14, 2015
1 parent ab87796 commit 8111083
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -158,7 +158,7 @@ private void prepConfigFile(Details details) throws IOException
localProperties.setProperty("server." + spec.getServerId(), spec.getHostname() + portSpec + spec.getServerType().getZookeeperConfigValue());
}

if ( usState.getUs().getServerType() == ServerType.OBSERVER )
if ( (usState.getUs() != null) && (usState.getUs().getServerType() == ServerType.OBSERVER) )
{
localProperties.setProperty("peerType", "observer");
}
Expand Down

0 comments on commit 8111083

Please sign in to comment.