Skip to content

Commit

Permalink
Do not use unsupported API
Browse files Browse the repository at this point in the history
  • Loading branch information
platan committed Oct 20, 2023
1 parent 9b27d5d commit f086952
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/main/java/hello/helpers/HelloHelper.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
package hello.helpers;

import com.google.common.base.Objects;
import pl.allegro.tech.boot.autoconfigure.handlebars.HandlebarsHelper;

@HandlebarsHelper
public class HelloHelper {

public String sayHello(String name) {
return String.format("Hello %s!", Objects.firstNonNull(name, "unknown"));
return String.format("Hello %s!", name == null ? "unknown" : name);
}
}

0 comments on commit f086952

Please sign in to comment.