You've already forked AstralRinth
forked from didirus/AstralRinth
fix: DI nonsense (#4174)
* fix: DI nonsense * fix: lint * fix: client try di issue * fix: injects outside of context * fix: use .catch * refactor: convert projects.vue to composition API. * fix: moderation checklist notif pos change watcher * fix: lint issues
This commit is contained in:
@@ -137,28 +137,10 @@ export const userFollowProject = async (project) => {
|
||||
}
|
||||
}
|
||||
export const resendVerifyEmail = async () => {
|
||||
// const { injectNotificationManager } = await import("@modrinth/ui");
|
||||
// const { addNotification } = injectNotificationManager();
|
||||
|
||||
startLoading()
|
||||
try {
|
||||
await useBaseFetch('auth/email/resend_verify', {
|
||||
method: 'POST',
|
||||
})
|
||||
|
||||
const auth = await useAuth()
|
||||
addNotification({
|
||||
title: 'Email sent',
|
||||
text: `An email with a link to verify your account has been sent to ${auth.value.user.email}.`,
|
||||
type: 'success',
|
||||
})
|
||||
} catch (err) {
|
||||
addNotification({
|
||||
title: 'An error occurred',
|
||||
text: err.data.description,
|
||||
type: 'error',
|
||||
})
|
||||
}
|
||||
await useBaseFetch('auth/email/resend_verify', {
|
||||
method: 'POST',
|
||||
})
|
||||
await useAuth()
|
||||
stopLoading()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user