mirror of
https://github.com/cryptomator/cryptomator.git
synced 2026-05-18 18:51:26 +00:00
change getProperty(key, default) and add unit test
This commit is contained in:
@@ -29,12 +29,8 @@ public class SubstitutingProperties extends PropertiesDecorator {
|
||||
|
||||
@Override
|
||||
public String getProperty(String key, String defaultValue) {
|
||||
var value = delegate.getProperty(key, defaultValue);
|
||||
if (key.startsWith("cryptomator.") && value != null) {
|
||||
return process(value);
|
||||
} else {
|
||||
return value;
|
||||
}
|
||||
var result = getProperty(key);
|
||||
return result != null ? result : defaultValue;
|
||||
}
|
||||
|
||||
//visible for testing
|
||||
|
||||
Reference in New Issue
Block a user