Skip to content

Commit

Permalink
Merge pull request #1408 from danskernesdigitalebibliotek/DDFBRA-41-p…
Browse files Browse the repository at this point in the history
…roxy-url-bliver-ikke-vist-pa-knappen-se-online

Fix URL proxies
  • Loading branch information
Adamik10 authored Sep 10, 2024
2 parents 4901097 + ddae4e9 commit 81435a4
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const MaterialButtonOnlineExternal: FC<MaterialButtonOnlineExternalProps> = ({

// Handle URL translation when data or error changes
useEffect(() => {
if (urlWasTranslated === false && !error && data?.data?.url) {
if (!urlWasTranslated && !error && data?.data?.url) {
setTranslatedUrl(new URL(data.data.url));
setUrlWasTranslated(true);
}
Expand Down

0 comments on commit 81435a4

Please sign in to comment.