Improved code.
This commit is contained in:
parent
a18fab99dc
commit
cfc1b78c99
3 changed files with 40 additions and 3 deletions
|
@ -132,7 +132,7 @@ public class Builder
|
|||
{
|
||||
File file = new File(configuration.getBuildDirectory(), configuration.getBuildInput().getName());
|
||||
|
||||
if ((file.isFile()) && (StringUtils.endsWithAny(file.getName(), ".properties")))
|
||||
if ((file.isFile()) && (StringUtils.endsWith(file.getName(), ".properties")))
|
||||
{
|
||||
logger.info("BUILDER : Deleting {}", file.getAbsolutePath());
|
||||
file.delete();
|
||||
|
|
|
@ -212,7 +212,7 @@ public final class StatoolInfosCLI
|
|||
}
|
||||
});
|
||||
|
||||
logger.info("{} StatoolInfos call: {}", LocalDateTime.now(), new StringList(args).toStringSeparatedBy(" "));
|
||||
logger.debug("{} StatoolInfos call: {}", LocalDateTime.now(), new StringList(args).toStringSeparatedBy(" "));
|
||||
|
||||
if (isMatching(args))
|
||||
{
|
||||
|
|
|
@ -277,7 +277,7 @@ public class Organization extends PathPropertyList
|
|||
{
|
||||
URL result;
|
||||
|
||||
String path = get("organization.logo");
|
||||
String path = getLogoURLValue();
|
||||
if ((StringUtils.isBlank(path)) || (!StringUtils.startsWith(path, "http")))
|
||||
{
|
||||
result = null;
|
||||
|
@ -291,6 +291,21 @@ public class Organization extends PathPropertyList
|
|||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the logo URL value.
|
||||
*
|
||||
* @return the logo URL value
|
||||
*/
|
||||
public String getLogoURLValue()
|
||||
{
|
||||
String result;
|
||||
|
||||
result = get("organization.logo");
|
||||
|
||||
//
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the mastodon page.
|
||||
*
|
||||
|
@ -596,6 +611,28 @@ public class Organization extends PathPropertyList
|
|||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if is default.
|
||||
*
|
||||
* @return true, if is default
|
||||
*/
|
||||
public boolean isDefault()
|
||||
{
|
||||
boolean result;
|
||||
|
||||
if ((getServiceCount() == 0) && (getLogoURLValue() == null) && (getStartDate() == null))
|
||||
{
|
||||
result = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
result = false;
|
||||
}
|
||||
|
||||
//
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if is valid.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue