Skip to content

Commit

Permalink
Renames annotation
Browse files Browse the repository at this point in the history
Fixes: OX-10994
  • Loading branch information
idlira committed May 21, 2024
1 parent e040687 commit 305f34a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@
@Documented
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.FIELD)
public @interface RemoveWhiteSpaces {
public @interface RemoveWhitespace {
}
4 changes: 2 additions & 2 deletions src/main/java/sirius/db/mixing/properties/StringProperty.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
import sirius.db.mixing.annotations.DefaultValue;
import sirius.db.mixing.annotations.Lob;
import sirius.db.mixing.annotations.LowerCase;
import sirius.db.mixing.annotations.RemoveWhiteSpaces;
import sirius.db.mixing.annotations.RemoveWhitespace;
import sirius.db.mixing.annotations.Trim;
import sirius.db.mixing.annotations.UpperCase;
import sirius.kernel.commons.StringCleanup;
Expand Down Expand Up @@ -78,7 +78,7 @@ protected StringProperty(EntityDescriptor descriptor, AccessPath accessPath, Fie
this.lowerCase = field.isAnnotationPresent(LowerCase.class);
this.upperCase = field.isAnnotationPresent(UpperCase.class);
this.lob = field.isAnnotationPresent(Lob.class);
this.removeWhiteSpaces = field.isAnnotationPresent(RemoveWhiteSpaces.class);
this.removeWhiteSpaces = field.isAnnotationPresent(RemoveWhitespace.class);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import sirius.db.mixing.annotations.Length;
import sirius.db.mixing.annotations.LowerCase;
import sirius.db.mixing.annotations.NullAllowed;
import sirius.db.mixing.annotations.RemoveWhiteSpaces;
import sirius.db.mixing.annotations.RemoveWhitespace;
import sirius.db.mixing.annotations.Trim;
import sirius.db.mixing.annotations.UpperCase;

Expand Down Expand Up @@ -53,7 +53,7 @@ public class StringManipulationTestEntity extends SQLEntity {
public static final Mapping REMOVE_WHITE_SPACES = Mapping.named("removeWhiteSpaces");
@Length(100)
@NullAllowed
@RemoveWhiteSpaces
@RemoveWhitespace
private String removeWhiteSpaces;

public String getTrimmed() {
Expand Down

0 comments on commit 305f34a

Please sign in to comment.