Got bug with .promise.then and it affected to loaded finish state
Closed this issue · 0 comments
I got bug like this :
Warning: Unhandled rejection: TypeError: Cannot read property 'then' of undefined
TypeError: Cannot read property 'then' of undefined
at Object.onResolve (http://localhost:8080/ng-pdfviewer-develop/example/ng-pdfviewer.js:60:69)
at Object.ea.runHandlers (http://localhost:8080/ng-pdfviewer-develop/example/pdf.js:20:252)
Once I just run the example page.
So, this bug comes from file ng-pdfviewer.js line 60 that called .render().promise.then
This problem is affected to PDF finish loaded state. I cannot track for PDF loaded state if it finish(Because it error and it stuck in ng-pdfviewer.js).
I just remove .promise and it's worked for me so that I can track if PDF loaded.
Please fix this.
Thank you