Skip to content

Commit 38ad2ba

Browse files
committed
Filter grepcodes before fetching
1 parent dbcaab9 commit 38ad2ba

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/resolvers/articleResolvers.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,10 @@ export const resolvers = {
4646
article.supportedLanguages?.find((lang) => lang === context.language) ??
4747
article.supportedLanguages?.[0] ??
4848
context.language;
49-
const result = await grepSearch({ codes: article.grepCodes, language: language }, context);
49+
const result = await grepSearch(
50+
{ codes: article.grepCodes.filter((code) => code.startsWith("KM")), language: language },
51+
context,
52+
);
5053
return result.results.map((hit) => {
5154
return {
5255
...hit,

0 commit comments

Comments
 (0)