fix(ADRs): handle trailing slashes and collator errors

Signed-off-by: Phil Kuang <pkuang@factset.com>
This commit is contained in:
Phil Kuang
2022-08-19 09:33:18 -04:00
parent c64dd8313d
commit b489de83b1
4 changed files with 22 additions and 7 deletions
@@ -45,7 +45,7 @@ export const AdrReader = (props: {
const adrLocationUrl = getAdrLocationUrl(entity, scmIntegrations);
const { value, loading, error } = useOctokitRequest(
`${adrLocationUrl}/${adr}`,
`${adrLocationUrl.replace(/\/$/, '')}/${adr}`,
);
const adrContent = useMemo(() => {