[fix] Increment cache version after object/field/relation update (#5316)

Fixes #5276.

Updates were not triggering a cache version incrementation because they
do not trigger migrations while that is where the caching version logic
was.
We have decided to move the cache incrementation logic to the services.
This commit is contained in:
Marie
2024-05-07 16:30:25 +02:00
committed by GitHub
parent b0d1cc9dcb
commit 7c3e82870c
22 changed files with 160 additions and 39 deletions

View File

@ -2,7 +2,7 @@ import { useMutation } from '@apollo/client';
import { getOperationName } from '@apollo/client/utilities';
import {
UpdateObjectInput,
UpdateOneObjectInput,
UpdateOneObjectMetadataItemMutation,
UpdateOneObjectMetadataItemMutationVariables,
} from '~/generated-metadata/graphql';
@ -27,8 +27,8 @@ export const useUpdateOneObjectMetadataItem = () => {
idToUpdate,
updatePayload,
}: {
idToUpdate: UpdateOneObjectMetadataItemMutationVariables['idToUpdate'];
updatePayload: UpdateObjectInput;
idToUpdate: UpdateOneObjectInput['id'];
updatePayload: UpdateOneObjectInput['update'];
}) => {
return await mutate({
variables: {