@vocollege/app 0.0.113 → 0.0.114

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -116,11 +116,16 @@ var GraphClient = /** @class */ (function () {
116
116
  cache: new client_1.InMemoryCache({
117
117
  typePolicies: {
118
118
  Education: {
119
- keyFields: [
120
- "id",
121
- "pivot",
122
- ["education_usage_id", "education_usage_type", "field"],
123
- ],
119
+ keyFields: function (object, context) {
120
+ if (!object.hasOwnProperty("pivot")) {
121
+ return ["id"];
122
+ }
123
+ return [
124
+ "id",
125
+ "pivot",
126
+ ["education_usage_id", "education_usage_type", "field"],
127
+ ];
128
+ },
124
129
  },
125
130
  // PivotEducation: {
126
131
  // // keyFields: ["education_usage_id"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vocollege/app",
3
- "version": "0.0.113",
3
+ "version": "0.0.114",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -70,11 +70,17 @@ class GraphClient {
70
70
  cache: new InMemoryCache({
71
71
  typePolicies: {
72
72
  Education: {
73
- keyFields: [
74
- "id",
75
- "pivot",
76
- ["education_usage_id", "education_usage_type", "field"],
77
- ],
73
+ keyFields: (object, context) => {
74
+ if (!object.hasOwnProperty("pivot")) {
75
+ return ["id"];
76
+ }
77
+
78
+ return [
79
+ "id",
80
+ "pivot",
81
+ ["education_usage_id", "education_usage_type", "field"],
82
+ ];
83
+ },
78
84
  },
79
85
  // PivotEducation: {
80
86
  // // keyFields: ["education_usage_id"],