Skip to content

Instantly share code, notes, and snippets.

@abayer
Created August 17, 2012 18:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abayer/3381305 to your computer and use it in GitHub Desktop.
Save abayer/3381305 to your computer and use it in GitHub Desktop.
diff --git a/core/src/main/java/org/apache/whirr/ClusterSpec.java b/core/src/main/java/org/apache/whirr/ClusterSpec.java
index 594220e..503a479 100644
--- a/core/src/main/java/org/apache/whirr/ClusterSpec.java
+++ b/core/src/main/java/org/apache/whirr/ClusterSpec.java
@@ -482,7 +482,7 @@ public class ClusterSpec {
}
private float getFloat(Property key, float defaultValue) {
- return config.getFloat(key.getConfigName(), defaultValue);
+ return config.getFloat(key.getConfigName(), defaultValue > 0 ? defaultValue : null);
}
private List<String> getList(Property key) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment