Replace null and empty check with isNullOrEmpty
Change-Id: Ic3f2bddeb0fecf058156a58977bc4238c6dc7a40
This commit is contained in:
@@ -14,6 +14,8 @@
|
||||
|
||||
package com.google.gerrit.server.mail.send;
|
||||
|
||||
import static com.google.common.base.Strings.isNullOrEmpty;
|
||||
|
||||
import com.google.gerrit.common.Nullable;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@@ -46,7 +48,7 @@ public class CommentFormatter {
|
||||
* @return List of block objects, each with unescaped comment content.
|
||||
*/
|
||||
public static List<Block> parse(@Nullable String source) {
|
||||
if (source == null || source.isEmpty()) {
|
||||
if (isNullOrEmpty(source)) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user