mirror of
https://github.com/ysoftdevs/DependencyCheck.git
synced 2026-01-14 15:53:36 +01:00
minor formating updatae
This commit is contained in:
@@ -149,13 +149,16 @@ public final class FileUtils {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Gets the {@link InputStream} for this resource
|
||||
*
|
||||
* @param resource path
|
||||
* @return
|
||||
*/
|
||||
public static InputStream getResourceAsStream(String resource) {
|
||||
return FileUtils.class.getClassLoader()!=null?FileUtils.class.getClassLoader().getResourceAsStream(resource):ClassLoader.getSystemResourceAsStream(resource);
|
||||
return FileUtils.class.getClassLoader() != null
|
||||
? FileUtils.class.getClassLoader().getResourceAsStream(resource)
|
||||
: ClassLoader.getSystemResourceAsStream(resource);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -260,7 +260,8 @@ public final class Settings {
|
||||
*/
|
||||
public static final String ANALYZER_NODE_PACKAGE_ENABLED = "analyzer.node.package.enabled";
|
||||
/**
|
||||
* The properties key for whether the Node Security Platform (nsp) analyzer is enabled.
|
||||
* The properties key for whether the Node Security Platform (nsp)
|
||||
* analyzer is enabled.
|
||||
*/
|
||||
public static final String ANALYZER_NSP_PACKAGE_ENABLED = "analyzer.nsp.package.enabled";
|
||||
/**
|
||||
@@ -745,8 +746,8 @@ public final class Settings {
|
||||
String decodedPath = ".";
|
||||
String jarPath = "";
|
||||
ProtectionDomain domain = Settings.class.getProtectionDomain();
|
||||
if(domain!=null&& domain.getCodeSource()!=null && domain.getCodeSource().getLocation()!=null) {
|
||||
jarPath = Settings.class.getProtectionDomain().getCodeSource().getLocation().getPath();
|
||||
if (domain != null && domain.getCodeSource() != null && domain.getCodeSource().getLocation() != null) {
|
||||
jarPath = Settings.class.getProtectionDomain().getCodeSource().getLocation().getPath();
|
||||
}
|
||||
try {
|
||||
decodedPath = URLDecoder.decode(jarPath, "UTF-8");
|
||||
|
||||
Reference in New Issue
Block a user