Skip to content
This repository has been archived by the owner on Apr 23, 2024. It is now read-only.

Commit

Permalink
Merge pull request #168 from mgilangjanuar/staging
Browse files Browse the repository at this point in the history
hotfix: get urls
  • Loading branch information
mgilangjanuar authored Jan 5, 2022
2 parents 56eceee + 122e284 commit 9b768dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/src/pages/View.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ const View: React.FC<PageProps & { me?: any, errorMe?: any }> = ({ match, me, er
useEffect(() => {
if (data?.file) {
setLinks({
raw: `${apiUrl || `${window.location.origin}/api/v1`}/files/${match.params.id}?raw=1`,
download: `${apiUrl || `${window.location.origin}/api/v1`}/files/${match.params.id}?raw=1&dl=1`,
raw: `${process.env.REACT_APP_API_URL || window.location.origin}/api/v1/files/${match.params.id}?raw=1`,
download: `${process.env.REACT_APP_API_URL || window.location.origin}/api/v1/files/${match.params.id}?raw=1&dl=1`,
share: `${window.location.origin}/view/${match.params.id}`
})
}
Expand Down

0 comments on commit 9b768dd

Please sign in to comment.