Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
fpseverino authored Dec 15, 2024
1 parent ec87aa6 commit 054a6ff
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Usage in a route closure would be as followed:
import SendGrid

let email = SendGridEmail()
try await req.sendgrid.client.send(email)
try await req.sendgrid.client.send(email: email)
```

### Error handling
Expand All @@ -64,8 +64,8 @@ Simply ensure you catch errors thrown like any other throwing function.

```swift
do {
try await req.sendgrid.client.send(email)
try await req.sendgrid.client.send(email: email)
} catch let error as SendGridError {
req.logger.error("\(error.errors)")
req.logger.error("\(error.errors)")
}
```

0 comments on commit 054a6ff

Please sign in to comment.