Skip to content

Commit

Permalink
Enable requests for OSF Preprints reviews
Browse files Browse the repository at this point in the history
  • Loading branch information
thewilkybarkid committed May 2, 2024
1 parent bb79b16 commit c4282cd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/review-request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import type {
BiorxivPreprintId,
EdarxivPreprintId,
MedrxivPreprintId,
OsfPreprintsPreprintId,
PreprintId,
PsyarxivPreprintId,
ScieloPreprintId,
Expand All @@ -22,6 +23,7 @@ export type ReviewRequestPreprintId =
| BiorxivPreprintId
| EdarxivPreprintId
| MedrxivPreprintId
| OsfPreprintsPreprintId
| PsyarxivPreprintId
| ScieloPreprintId

Expand Down Expand Up @@ -101,6 +103,6 @@ export const saveReviewRequest = (

export function isReviewRequestPreprintId(preprint: PreprintId): preprint is ReviewRequestPreprintId {
return match(preprint.type)
.with('arxiv', 'biorxiv', 'edarxiv', 'medrxiv', 'psyarxiv', 'scielo', () => true)
.with('arxiv', 'biorxiv', 'edarxiv', 'medrxiv', 'osf-preprints', 'psyarxiv', 'scielo', () => true)
.otherwise(() => false)
}
2 changes: 1 addition & 1 deletion test/fc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -818,6 +818,7 @@ export const reviewRequestPreprintId = (): fc.Arbitrary<ReviewRequestPreprintId>
biorxivPreprintId(),
edarxivPreprintId(),
medrxivPreprintId(),
osfPreprintsPreprintId(),
psyarxivPreprintId(),
scieloPreprintId(),
)
Expand All @@ -832,7 +833,6 @@ export const notAReviewRequestPreprintId = (): fc.Arbitrary<Exclude<PreprintId,
engrxivPreprintId(),
metaarxivPreprintId(),
osfPreprintId(),
osfPreprintsPreprintId(),
philsciPreprintId(),
preprintsorgPreprintId(),
psychArchivesPreprintId(),
Expand Down

0 comments on commit c4282cd

Please sign in to comment.