Merge pull request #514 from flisky/fix-doc

doc: validator attribute under graphql macro
This commit is contained in:
Sunli 2021-05-19 10:58:08 +08:00 committed by GitHub
commit b656bdcc31
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -31,11 +31,11 @@ struct Query;
#[Object]
impl Query {
async fn input(#[validator(
async fn input(#[graphql(validator(
or(
and(IntGreaterThan(value = "10"), IntLessThan(value = "100")),
IntEqual(value = "0")
))] a: String) {
)))] a: String) {
} {
}
}

View File

@ -29,11 +29,11 @@ struct Query;
#[Object]
impl Query {
async fn input(#[validator(
async fn input(#[graphql(validator(
or(
and(IntGreaterThan(value = "10"), IntLessThan(value = "100")),
IntEqual(value = "0")
))] a: String) {
)))] a: String) {
} {
}
}