Fix some issues found by qodana (#2083)

Signed-off-by: Avgustin Marinov <Avgustin.Marinov@bosch.com>
This commit is contained in:
Avgustin Marinov
2024-11-19 17:04:19 +02:00
committed by GitHub
parent 9c8c82fd8b
commit a3468b2ba9
47 changed files with 124 additions and 98 deletions

View File

@@ -11,6 +11,7 @@ package org.eclipse.hawkbit.repository.builder;
import java.util.Optional;
import lombok.Getter;
import org.eclipse.hawkbit.repository.ValidString;
import org.springframework.util.StringUtils;
@@ -22,6 +23,7 @@ import org.springframework.util.StringUtils;
public abstract class AbstractMetadataUpdateCreate<T> {
@ValidString
@Getter
protected String key;
@ValidString
protected String value;
@@ -31,10 +33,6 @@ public abstract class AbstractMetadataUpdateCreate<T> {
return (T) this;
}
public String getKey() {
return key;
}
public T value(final String value) {
this.value = StringUtils.trimWhitespace(value);
return (T) this;