-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
-
I'm submitting a ...
[X] bug report
[ ] feature request
[ ] question about the decisions made in the repository
[ ] question about how to use this project -
Summary
The docs sayIf the tenant is already created: will return 200 instead of 201, and will return the existing tenant object in the response body.. However this is throwing an error without a try/catch:
try {
tenant = await permit.api.tenants.get(tenantKey)
} catch(e) {
tenant = await permit.api.tenants.create({ key: tenantKey, name: sender.tenant.name })
}
- Other information (e.g. detailed explanation, stack traces, related issues, suggestions how to fix, links for us to have context, eg. StackOverflow, personal fork, etc.)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels