Skip to content

Commit

Permalink
Merge pull request #671 from alexandear/docs-fix-typo
Browse files Browse the repository at this point in the history
docs: fix typos in request-validation.md
  • Loading branch information
danielgtaylor authored Dec 5, 2024
2 parents 53f6a5f + 286665e commit c4199b8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/docs/features/request-validation.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ type MyInput struct {
}
```

If you had used `bool` instead of `*bool` then the zero value of `false` would get overridden by the default value of `true`, even if false is explictly sent by the client.
If you had used `bool` instead of `*bool` then the zero value of `false` would get overridden by the default value of `true`, even if false is explicitly sent by the client.

### Read and Write Only

Expand All @@ -168,7 +168,7 @@ Write-only fields, if stored in a datastore, can be combined with `omitempty` an

!!! info "Note"

If a write-only field needs to be required on the request but the same struct is re-used in the response, you can use `json:"name,omitempy"` with `required:"true"`.
If a write-only field needs to be required on the request but the same struct is re-used in the response, you can use `json:"name,omitempty"` with `required:"true"`.

## Strict vs. Loose Field Validation

Expand Down

0 comments on commit c4199b8

Please sign in to comment.