String moduleKey = jsonProperty.get("p");
if (moduleKey == null || projectKey.equals(moduleKey)) {
setProperty(key, value);
- } else {
+ }
+ if (moduleKey != null) {
Map<String, String> map = moduleProperties.get(moduleKey);
if (map == null) {
map = Maps.newHashMap();
LoggerFactory.getLogger(ProjectSettings.class).info("Load module settings");
this.deprecatedCommonsConf = deprecatedCommonsConf;
- if (project.getParent() == null) {
- // root project -> no need to reload settings
- copy(batchSettings);
- } else {
- init(project, batchSettings);
- }
- }
-
- private void copy(BatchSettings batchSettings) {
- setProperties(batchSettings);
+ init(project, batchSettings);
}
private ProjectSettings init(ProjectDefinition project, BatchSettings batchSettings) {
return addProperties(props);
}
- public final Settings setProperties(Settings s) {
- if (s.properties == null) {
- return clear();
- }
- return setProperties(Maps.newHashMap(s.properties));
- }
-
public final Settings setProperty(String key, @Nullable Date date, boolean includeTime) {
return setProperty(key, includeTime ? DateUtils.formatDateTime(date) : DateUtils.formatDate(date));
}