Skip to content

Commit

Permalink
Update services.md (#9189)
Browse files Browse the repository at this point in the history
I've removed duplicated code
  • Loading branch information
papaponmx authored Sep 18, 2023
1 parent 4d06556 commit ba9461c
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions docs/docs/services.md
Original file line number Diff line number Diff line change
Expand Up @@ -626,12 +626,6 @@ validateWithSync(() => {
throw "You'll have to be more creative than that"
}
})

validateWithSync(() => {
if (input.name === 'Name') {
throw new Error("You'll have to be more creative than that")
}
})
```
Either of these errors will be caught and re-thrown as a `ServiceValidationError` with your text as the `message` of the error (although technically you should always throw errors with `new Error()` like in the second example).
Expand Down

0 comments on commit ba9461c

Please sign in to comment.