Skip to content

Commit

Permalink
fix(suite): error page link relative
Browse files Browse the repository at this point in the history
- We use ASSET_PREFIX including trailing slash, Chrome interpret // as absolute link.

(cherry picked from commit 3d03e06)
  • Loading branch information
matejkriz committed Aug 4, 2023
1 parent e3865ac commit 50cdcb4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/suite/src/views/suite/ErrorPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const Wrapper = styled.div`
`;

export const ErrorPage = () => {
const assetPrefix = process.env.ASSET_PREFIX || '';
const link = process.env.ASSET_PREFIX || '/';

return (
<Wrapper>
Expand All @@ -25,7 +25,7 @@ export const ErrorPage = () => {
<Translation id="TR_404_DESCRIPTION" />
</P>
<Image image="ERROR_404" />
<Link variant="nostyle" target="_self" href={`/${assetPrefix}`}>
<Link variant="nostyle" target="_self" href={link}>
<Button>
<Translation id="TR_404_GO_TO_DASHBOARD" />
</Button>
Expand Down

0 comments on commit 50cdcb4

Please sign in to comment.