Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unhandled promise rejection when using Repository.isCollaborator() #629

Open
sulkaharo opened this issue Oct 27, 2020 · 0 comments
Open

Comments

@sulkaharo
Copy link

When calling Repository.isCollaborator(), the a UnhandledPromiseRejectionWarning: Error: 404 error making request get https://api.github.com/repos/org/repo/collaborators/xxx: "Not Found" is thrown when a user is not a collaborator, instead of returning false, and if the user is a collaborator, the request object is returned with blank data field. Based on the documentation, the promise should resolve to a boolean, but this doesn't seem to be the case with how actual behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant