javascript: fix the progress bar removal on success
When using auto-attach, the response HTML fragment replaces the progress bar – so it doesn't need to be removed twice.
This commit is contained in:
parent
647ad3ba10
commit
769e98f63e
1 changed files with 4 additions and 3 deletions
|
@ -30,10 +30,11 @@ export default class Uploader {
|
||||||
|
|
||||||
if (this.autoAttachUrl) {
|
if (this.autoAttachUrl) {
|
||||||
await this._attach(blobSignedId);
|
await this._attach(blobSignedId);
|
||||||
}
|
// On response, the attachment HTML fragment will replace the progress bar.
|
||||||
|
} else {
|
||||||
this.progressBar.end();
|
this.progressBar.end();
|
||||||
this.progressBar.destroy();
|
this.progressBar.destroy();
|
||||||
|
}
|
||||||
|
|
||||||
return blobSignedId;
|
return blobSignedId;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|
Loading…
Reference in a new issue