Skip to content

Commit 3cf007f

Browse files
committed
Fix method signature in UserSchema age_in_range rule
1 parent 156648f commit 3cf007f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/blog/validation-libs-2025/index.qmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ class UserSchema(dy.Schema):
548548
549549
# Use @dy.rule() for age range validation
550550
@dy.rule()
551-
def age_in_range() -> pl.Expr:
551+
def age_in_range(cls) -> pl.Expr:
552552
return pl.col("age").is_between(18, 80, closed="both")
553553
554554
# Validate using the schema

0 commit comments

Comments
 (0)