From 4499c22043eb437cbb95eb9a26edb82e9ddec88f Mon Sep 17 00:00:00 2001 From: gmungoc Date: Mon, 23 Jul 2018 11:56:11 +0100 Subject: [PATCH] JAL-3048 javadoc and code tidy --- src/jalview/bin/Cache.java | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/jalview/bin/Cache.java b/src/jalview/bin/Cache.java index 1f031b2..b6315f3 100755 --- a/src/jalview/bin/Cache.java +++ b/src/jalview/bin/Cache.java @@ -604,18 +604,13 @@ public class Cache } /** - * These methods are used when checking if the saved preference is different - * to the default setting + * Answers the value of the given property, or the supplied default value if + * the property is not set */ public static String getDefault(String property, String def) { - String string = getProperty(property); - if (string != null) - { - return string; - } - - return def; + String value = getProperty(property); + return value == null ? def : value; } /** -- 1.7.10.2