Skip to content

Commit

Permalink
remove logs
Browse files Browse the repository at this point in the history
  • Loading branch information
bogdanfazakas committed Jan 5, 2023
1 parent 3e0e578 commit 6046a03
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/utils/FetchHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@ import { DownloadResponse } from '../@types'
export async function downloadFileBrowser(url: string): Promise<void> {
const headResponse = await fetch(url, { method: 'HEAD' })
const contentHeader = headResponse.headers.get('content-disposition')
console.log('contentHeader', contentHeader)
const fileName =
contentHeader && contentHeader?.split('=')[1] ? contentHeader?.split('=')[1] : 'file'
const fileName = contentHeader?.split('=')[1] ? contentHeader?.split('=')[1] : 'file'
const xhr = new XMLHttpRequest()
xhr.responseType = 'blob'
xhr.open('GET', url)
Expand Down

0 comments on commit 6046a03

Please sign in to comment.