Skip to content

Commit 7e17c64

Browse files
committed
changed to read only from github
1 parent ca01f01 commit 7e17c64

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

nextstep-frontend/src/handlers/githubAuth.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export const connectToGitHub = async (username: string) => {
2626
export const initiateGitHubOAuth = () => {
2727
const clientId = import.meta.env.VITE_GITHUB_CLIENT_ID; // Use environment variable
2828
const redirectUri = import.meta.env.VITE_GITHUB_REDIRECT_URI; // Use environment variable
29-
const scope = 'repo'; // Adjust scope as needed
29+
const scope = 'read:repo'; // Only read access to repositories
3030
const authUrl = `https://github.com/login/oauth/authorize?client_id=${clientId}&redirect_uri=${redirectUri}&scope=${scope}`;
3131
window.location.href = authUrl; // Redirect the user to GitHub's authorization page
3232
};

0 commit comments

Comments
 (0)