diff --git a/app/src/main/java/com/wireguard/android/model/Tunnel.java b/app/src/main/java/com/wireguard/android/model/Tunnel.java index 7a0972c3..9bb7406c 100644 --- a/app/src/main/java/com/wireguard/android/model/Tunnel.java +++ b/app/src/main/java/com/wireguard/android/model/Tunnel.java @@ -37,8 +37,8 @@ public class Tunnel extends BaseObservable implements Keyed { this.state = state; } - public static boolean isNameValid(final CharSequence name) { - return name != null && NAME_PATTERN.matcher(name).matches(); + public static boolean isNameValid(@NonNull final CharSequence name) { + return NAME_PATTERN.matcher(name).matches(); } public CompletionStage delete() {