Skip to content

Commit 846bb55

Browse files
committed
Update gitauth.js
1 parent f474938 commit 846bb55

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

git/gitauth.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,15 +59,17 @@ window.onload = async () => {
5959
}
6060

6161

62+
const authURL = 'https://github.com/login/oauth/authorize?client_id=7ede3eed3185e59c042d&scope=repo,user,write:org';
63+
6264
loginButton.addEventListener('click', () => {
6365

6466
if (isMobile) {
6567

66-
window.location.href = 'https://github.com/login/oauth/authorize?client_id=7ede3eed3185e59c042d&scope=repo,user,write:org';
68+
window.location.href = authURL;
6769

6870
} else {
6971

70-
window.open('https://github.com/login/oauth/authorize?client_id=7ede3eed3185e59c042d&scope=repo,user,write:org', 'Login with Github', 'height=575,width=575');
72+
window.open(authURL, 'Login with Github', 'height=575,width=575');
7173

7274
}
7375

@@ -77,7 +79,7 @@ window.onload = async () => {
7779
window.addEventListener('message', (event) => {
7880

7981
// if redirected from git auth
80-
if (event.source.location.pathname === '/git/login') {
82+
if (event.source.location.pathname === '/git/github/oauth') {
8183

8284
// hide intro screen
8385
sidebar.classList.remove('intro');

0 commit comments

Comments
 (0)