Skip to content

Commit d5e11b8

Browse files
committed
Preserve existing cache
1 parent 1ded9c5 commit d5e11b8

File tree

1 file changed

+4
-5
lines changed
  • packages/gitbook/src/lib

1 file changed

+4
-5
lines changed

packages/gitbook/src/lib/api.ts

+4-5
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,6 @@ interface GetRevisionOptions {
380380

381381
/**
382382
* Additional tags to add to the cache entry.
383-
* It's only used for v1, once in v2 we can get rid of it.
384383
*/
385384
tags?: string[];
386385
}
@@ -433,8 +432,8 @@ export const getRevision = cache({
433432
});
434433
},
435434
getKeyArgs: ([spaceId, revisionId, fetchOptions]) => {
436-
if (fetchOptions.computed === false) {
437-
return [spaceId, revisionId, { computed: false }];
435+
if (fetchOptions.computed === true) {
436+
return [spaceId, revisionId, { computed: true }];
438437
}
439438
return [spaceId, revisionId];
440439
},
@@ -480,8 +479,8 @@ export const getRevisionPages = cache({
480479
});
481480
},
482481
getKeyArgs: ([spaceId, revisionId, fetchOptions]) => {
483-
if (fetchOptions.computed === false) {
484-
return [spaceId, revisionId, { computed: false }];
482+
if (fetchOptions.computed === true) {
483+
return [spaceId, revisionId, { computed: true }];
485484
}
486485
return [spaceId, revisionId];
487486
},

0 commit comments

Comments
 (0)