Remove modules from manual cache definition

This commit is contained in:
Ramon Wenger 2020-01-07 16:11:17 +01:00 committed by Ramon Wenger
parent 374186ed27
commit bc9bf8cdec
1 changed files with 1 additions and 2 deletions

View File

@ -78,8 +78,6 @@ export default function (uri) {
assignment: (_, args, {getCacheKey}) => getCacheKey({__typename: 'AssignmentNode', id: args.id}),
objective: (_, args, {getCacheKey}) => getCacheKey({__typename: 'ObjectiveNode', id: args.id}),
objectiveGroup: (_, args, {getCacheKey}) => getCacheKey({__typename: 'ObjectiveGroupNode', id: args.id}),
// todo: remove, the new client seems to cache this correctly by itself
// module: (_, args, {getCacheKey}) => getCacheKey({__typename: 'ModuleNode', id: args.slug}),
projectEntry: (_, args, {getCacheKey}) => getCacheKey({__typename: 'ProjectEntryNode', id: args.id}),
}
}
@ -93,6 +91,7 @@ export default function (uri) {
try {
return cache.originalReadQuery(...args);
} catch (err) {
console.error(err);
return undefined;
}
};