Skip to content

Commit 7e7f930

Browse files
Turn off caching for fetchAllShortTandemRepeats
1 parent a2fc161 commit 7e7f930

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

graphql-api/src/queries/short-tandem-repeat-queries.ts

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { withCache } from '../cache'
21
import { DATASET_LABELS } from '../datasets'
32
import { UserVisibleError } from '../errors'
43
import { fetchAllSearchResults } from './helpers/elasticsearch-helpers'
@@ -18,7 +17,7 @@ const SUMMARY_FIELDS = [
1817
'value.reference_repeat_unit',
1918
]
2019

21-
const _fetchAllShortTandemRepeats = async (esClient: any, datasetId: any) => {
20+
export const fetchAllShortTandemRepeats = async (esClient: any, datasetId: any) => {
2221
// @ts-expect-error TS(7053) FIXME: Element implicitly has an 'any' type because expre... Remove this comment to see the full error message
2322
if (!SHORT_TANDEM_REPEAT_INDICES[datasetId]) {
2423
throw new UserVisibleError(
@@ -44,12 +43,6 @@ const _fetchAllShortTandemRepeats = async (esClient: any, datasetId: any) => {
4443
return hits.map((hit: any) => hit._source.value)
4544
}
4645

47-
export const fetchAllShortTandemRepeats = withCache(
48-
_fetchAllShortTandemRepeats,
49-
(_: any, datasetId: any) => `short_tandem_repeats:${datasetId}`,
50-
{ expiration: 86400 }
51-
)
52-
5346
export const fetchShortTandemRepeatById = async (
5447
esClient: any,
5548
datasetId: any,

0 commit comments

Comments
 (0)