Merge branch 'fix-unfollow-group' into 'main'

Fix unfollowing group

See merge request framasoft/mobilizon!1343
This commit is contained in:
Thomas Citharel 2022-11-25 17:38:10 +00:00
commit 8f4f303a70

View File

@ -662,7 +662,7 @@ import EmptyContent from "../../components/Utils/EmptyContent.vue";
import { Paginate } from "@/types/paginate"; import { Paginate } from "@/types/paginate";
import { IEvent } from "@/types/event.model"; import { IEvent } from "@/types/event.model";
import { IPost } from "@/types/post.model"; import { IPost } from "@/types/post.model";
import { FOLLOW_GROUP, UPDATE_GROUP_FOLLOW } from "@/graphql/followers"; import { FOLLOW_GROUP, UNFOLLOW_GROUP, UPDATE_GROUP_FOLLOW } from "@/graphql/followers";
import { useAnonymousReportsConfig } from "../../composition/apollo/config"; import { useAnonymousReportsConfig } from "../../composition/apollo/config";
import { computed, defineAsyncComponent, inject, ref, watch } from "vue"; import { computed, defineAsyncComponent, inject, ref, watch } from "vue";
import { useCurrentActorClient } from "@/composition/apollo/actor"; import { useCurrentActorClient } from "@/composition/apollo/actor";
@ -891,7 +891,7 @@ const followGroup = async (): Promise<void> => {
}; };
const { mutate: unfollowGroupMutation, onError: onUnfollowGroupError } = const { mutate: unfollowGroupMutation, onError: onUnfollowGroupError } =
useMutation(FOLLOW_GROUP, () => ({ useMutation(UNFOLLOW_GROUP, () => ({
refetchQueries: [ refetchQueries: [
{ {
query: PERSON_STATUS_GROUP, query: PERSON_STATUS_GROUP,