Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Error.Is interface method on the custom error type APIError. (#162)
This method supports doing "errors.Is" checks so downstream can handle API errors more specifically. In my case, since I copied your lazyClient example, but I'm using it in a server, the Login needs to be refreshed if an API call errors out with "api.err.LoginRequired". There was no clean way to check for this specific error in order to refresh the login and retry.
- Loading branch information