You've already forked AstralRinth
forked from didirus/AstralRinth
Fix issues (#158)
* Fix accept all button simply not working * Switched privacy settings icons to a shield Fixed auth changing the theme and consent Fixed server error on log in / out * Fixed scrolling issue on mobile * Fixed GPDR concerns
This commit is contained in:
@@ -22,21 +22,25 @@ export const mutations = {
|
||||
|
||||
export const actions = {
|
||||
async fetchUser({ commit }, { token }) {
|
||||
const user = (
|
||||
await this.$axios.get(`https://api.modrinth.com/api/v1/user`, {
|
||||
try {
|
||||
const user = (
|
||||
await this.$axios.get(`https://api.modrinth.com/api/v1/user`, {
|
||||
headers: {
|
||||
Authorization: token,
|
||||
},
|
||||
})
|
||||
).data
|
||||
|
||||
commit('SET_USER', user)
|
||||
commit('SET_TOKEN', token)
|
||||
commit('SET_HEADERS', {
|
||||
headers: {
|
||||
Authorization: token,
|
||||
},
|
||||
})
|
||||
).data
|
||||
|
||||
commit('SET_USER', user)
|
||||
commit('SET_TOKEN', token)
|
||||
commit('SET_HEADERS', {
|
||||
headers: {
|
||||
Authorization: token,
|
||||
},
|
||||
})
|
||||
} catch (e) {
|
||||
console.error('Request for user info encountered an error: ', e)
|
||||
}
|
||||
},
|
||||
async fetchUserFollows({ commit }, { userId, token }) {
|
||||
const follows = await this.$axios.get(
|
||||
@@ -47,7 +51,6 @@ export const actions = {
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
commit('SET_USER_FOLLOWS', follows)
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user