Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
hizclick authored Sep 28, 2023
1 parent 99c45ab commit aabfd96
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/store/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -432,14 +432,15 @@ export default createStore({
});

const url = `https://github.com/login/oauth/authorize?auth?code=${code}&${query}`
console.log(url)

fetch(url).then(resp => {
if (resp.ok) {
console.log("OK")
resp.json().then(data => {
const accessToken = data.access_token
if (accessToken) {
state.logedin = true

const userId = data.id;
commit('SET_ACCESS_TOKEN', { auth: accessToken})
commit('SET_OWNER')
Expand Down

0 comments on commit aabfd96

Please sign in to comment.