mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
Provide test case
This commit is contained in:
@@ -261,9 +261,11 @@ public class AnnotationFields extends AnnotationParser {
|
||||
// take the max size of all @Size annotations
|
||||
int maxSize = -1;
|
||||
for (Size size : getAll(prop, Size.class)) {
|
||||
maxSize = Math.max(maxSize, size.max());
|
||||
if (size.max() < Integer.MAX_VALUE) {
|
||||
maxSize = Math.max(maxSize, size.max());
|
||||
}
|
||||
}
|
||||
if (maxSize !=1 && maxSize < Integer.MAX_VALUE) {
|
||||
if (maxSize != -1) {
|
||||
prop.setDbLength(maxSize);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user