Skip to content

Commit

Permalink
Provide a correct URL when logging #3342
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinrutherford committed Jun 20, 2024
1 parent e7b22b1 commit 9c03a16
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,13 @@ const scietyLabsCategoriesResponseCodec = t.type({
})),
});

const url = 'https://labs.sciety.org/api/papers/v1/preprints/classifications?filter%5Bevaluated_only%5D=true';

export const fetchSearchCategories = (logger: Logger): ExternalQueries['fetchSearchCategories'] => () => pipe(
hardCodedResponse,
TE.right,
TE.chainEitherKW(flow(
decodeAndLogFailures(logger, scietyLabsCategoriesResponseCodec, { url: '' }),
decodeAndLogFailures(logger, scietyLabsCategoriesResponseCodec, { url }),
E.mapLeft(() => DE.unavailable),
)),
TE.map((response) => response.data),
Expand Down

0 comments on commit 9c03a16

Please sign in to comment.