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

Feature/127/save GitHub user #128

Merged
merged 6 commits into from
Feb 20, 2023
Merged

Conversation

martinrobled0
Copy link
Contributor

@martinrobled0 martinrobled0 commented Feb 3, 2023

What does this PR do?

Save the github user when, you log in, on the profile table if the user doesn't have that information

How should this be manually tested?

  1. Log out
  2. Log in
  3. Check your profile on the profile table

Any background context you want to provide?

This only will works if the user has a public email set on git hub.

What are the relevant tickets?

#127 #116

Screenshots

image

image

Questions

Checklist

  • I added the necessary documentation, if appropriate.
  • I added tests to prove that my fix is effective or my feature works.
  • I reviewed existing Pull Requests before submitting mine.

app/routes/api/github/get-getUserInfo.tsx Show resolved Hide resolved
const octokit = new Octokit({ USERNAME: env.AUTH0_CLIENT_SECRET });

export const getUserInfo = async (email: string) => {
return await octokit.request(`GET /search/users?q=${email}`);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have to handle an error, e.g. we consumed all of the free intents or something?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or time out?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nop, I'll check it

@martinrobled0 martinrobled0 merged commit b298274 into main Feb 20, 2023
@martinrobled0 martinrobled0 deleted the feature/127/save-github-user branch February 20, 2023 17:03
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

Successfully merging this pull request may close these issues.

2 participants