Skip to content

Commit

Permalink
fix: hydra prefix is not mandatory
Browse files Browse the repository at this point in the history
  • Loading branch information
soyuka committed Oct 1, 2024
1 parent e8b49f2 commit 0ca328b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/hydra/fetchResource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@ export default (
resourceUrl,
Object.assign({ itemsPerPage: 0 }, options)
).then((d) => ({
const hasPrefix = 'hydra:search' in d.body;

Check failure on line 13 in src/hydra/fetchResource.ts

View workflow job for this annotation

GitHub Actions / Continuous integration

':' expected.

Check failure on line 13 in src/hydra/fetchResource.ts

View workflow job for this annotation

GitHub Actions / Continuous integration

',' expected.

Check failure on line 13 in src/hydra/fetchResource.ts

View workflow job for this annotation

GitHub Actions / Continuous integration

':' expected.

Check failure on line 13 in src/hydra/fetchResource.ts

View workflow job for this annotation

GitHub Actions / Continuous integration

',' expected.
parameters: get(
d,
"body.hydra:search.hydra:mapping"
hasPrefix ? "body.hydra:search.hydra:mapping" : "body.search.mapping"
) as unknown as IriTemplateMapping[],
}));
};

0 comments on commit 0ca328b

Please sign in to comment.