Improve GraphQL documentation and cleanup API

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2020-11-19 17:06:28 +01:00
parent e8a3b6aa94
commit 3eacbb2ca3
87 changed files with 6542 additions and 6314 deletions

View File

@@ -30,11 +30,11 @@ export default class Validate extends Vue {
failed = false;
async created() {
async created(): Promise<void> {
await this.validateAction();
}
async validateAction() {
async validateAction(): Promise<void> {
try {
await this.$apollo.mutate<{ validateEmail: ICurrentUser }>({
mutation: VALIDATE_EMAIL,
@@ -43,11 +43,10 @@ export default class Validate extends Vue {
},
});
this.loading = false;
return await this.$router.push({ name: RouteName.HOME });
await this.$router.push({ name: RouteName.HOME });
} catch (err) {
console.error(err);
this.failed = true;
return undefined;
}
}
}