This looks behavior-preserving rather than a parser fix. The original condition already only keeps minItems when the value is 0 or 1; min_items == 1 is false for None, so the added tests would pass on the current code too.
If the goal is readability, it may be clearer to frame this as a small cleanup. If there is an actual failing schema case, the regression test should cover a value that fails before this change.
Originally posted by @kiwigitops in #1600 (comment)
This looks behavior-preserving rather than a parser fix. The original condition already only keeps
minItemswhen the value is0or1;min_items == 1is false forNone, so the added tests would pass on the current code too.If the goal is readability, it may be clearer to frame this as a small cleanup. If there is an actual failing schema case, the regression test should cover a value that fails before this change.
Originally posted by @kiwigitops in #1600 (comment)