Skip to content

Commit

Permalink
Sonar: Invoke method(s) only conditionally
Browse files Browse the repository at this point in the history
  • Loading branch information
qmonmert committed Sep 17, 2023
1 parent 365cf12 commit a15a4d5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/io/github/jhipster/online/JhonlineApp.java
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ private static void logApplicationStartup(Environment env) {
protocol = "https";
}
String serverPort = env.getProperty("server.port");
String applicationName = env.getProperty("spring.application.name");
String contextPath = env.getProperty("server.servlet.context-path");
if (StringUtils.isBlank(contextPath)) {
contextPath = "/";
Expand All @@ -109,7 +110,7 @@ private static void logApplicationStartup(Environment env) {
"Local: \t\t{}://localhost:{}{}\n\t" +
"External: \t{}://{}:{}{}\n\t" +
"Profile(s): \t{}\n----------------------------------------------------------",
env.getProperty("spring.application.name"),
applicationName,
protocol,
serverPort,
contextPath,
Expand Down

0 comments on commit a15a4d5

Please sign in to comment.