File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
main/java/org/mybatis/dynamic/sql
test/java/examples/animal/data Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,13 @@ public boolean skipRenderingWhenEmpty() {
4444 return skipRenderingWhenEmpty ;
4545 }
4646
47+ /**
48+ * Use with caution - this could cause the library to render invalid SQL like "where column in ()".
49+ */
50+ protected void forceRenderingWhenEmpty () {
51+ skipRenderingWhenEmpty = false ;
52+ }
53+
4754 @ Override
4855 public <R > R accept (ConditionVisitor <T , R > visitor ) {
4956 return visitor .visit (this );
Original file line number Diff line number Diff line change @@ -589,7 +589,7 @@ void testInConditionWithEmptyList() {
589589 public static class IsInRequired <T > extends IsIn <T > {
590590 protected IsInRequired (Collection <T > values ) {
591591 super (values );
592- skipRenderingWhenEmpty = false ;
592+ forceRenderingWhenEmpty () ;
593593 }
594594
595595 public static <T > IsInRequired <T > isIn (Collection <T > values ) {
You can’t perform that action at this time.
0 commit comments