Refactor constructors to use delegation for null sortField

This commit is contained in:
Cristiano Nascimeno 2024-10-31 18:16:40 -03:00
parent e5a029d318
commit bc7329eb6b
2 changed files with 2 additions and 4 deletions

View File

@ -36,8 +36,7 @@ public class ExtendedObjectResource<T extends BaseModel> extends BaseObjectResou
private final String sortField;
public ExtendedObjectResource(Class<T> baseClass) {
super(baseClass);
this.sortField = null;
this(baseClass, null);
}
public ExtendedObjectResource(Class<T> baseClass, String sortField) {

View File

@ -35,8 +35,7 @@ public class SimpleObjectResource<T extends BaseModel> extends BaseObjectResourc
private final String sortField;
public SimpleObjectResource(Class<T> baseClass) {
super(baseClass);
this.sortField = null;
this(baseClass, null);
}
public SimpleObjectResource(Class<T> baseClass, String sortField) {