mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-02-05 08:06:56 +07:00
11 lines
223 B
Java
11 lines
223 B
Java
// "Replace with Optional.ofNullable() chain" "GENERIC_ERROR_OR_WARNING"
|
|
|
|
import java.util.Optional;
|
|
|
|
class Test {
|
|
String foo;
|
|
|
|
String select() {
|
|
return Optional.ofNullable(foo).map(String::trim).orElse("");
|
|
}
|
|
} |