added size and duration to connection error reporting

This commit is contained in:
Danny Coates 2019-08-08 09:52:22 -07:00
parent 0729064753
commit 96c750c098
No known key found for this signature in database
GPG key ID: 4C442633C62E00CB
5 changed files with 28 additions and 19 deletions

View file

@ -153,7 +153,7 @@ export default class FileReceiver extends Nanobus {
const downloadPath = `/api/download/${this.fileInfo.id}`;
let downloadUrl = getApiUrl(downloadPath);
if (downloadUrl === downloadPath) {
downloadUrl = `${location.protocol}//${location.host}/api/download/${this.fileInfo.id}`;
downloadUrl = `${location.protocol}//${location.host}${downloadPath}`;
}
const a = document.createElement('a');
a.href = downloadUrl;