Merge pull request #4153 from sriram-dev/4027-destroy-previous-doc

4027 - Terminate worker of previous doc
This commit is contained in:
Yury Delendik 2014-01-20 17:56:56 -08:00
commit 8869b7e87e

View File

@ -524,6 +524,10 @@ var PDFView = {
}
}
// Terminate worker of the previous document if any.
if (this.pdfDocument) {
this.pdfDocument.destroy();
}
this.pdfDocument = null;
var self = this;
self.loading = true;