-
-
Notifications
You must be signed in to change notification settings - Fork 529
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
338 - Fix render method missing catch statement on render failure #346
Conversation
@dvago are you sure this fixes #338 ? The error message posted there is
Could it be that |
@justincpollard it basically fails within the Given the experience for the user is not breaking, the snippet, de facto, silences a random render failure, which eventually gets recalled. What you are referring to is a method on In general, it is best practice to attach the catch statement in any promise, so, in case, for any obscure reason, your promise fails something is ready to catch it. By the way, you can test the pull request yourself, just place the code change within the file in your project's node_modules/ and try to re-run to see if fixes the error. |
Right, so: #338 complains about a type error coming out from the Another possible fix would probably be to check for if (!pdfPage) {
return;
} in fact, I would probably add it as well, there is no point to move onward if the pdfPage isn't defined. |
Excuse me, when will this branch be merged? |
I believe all of us are waiting for it :) |
I tried this, but did not work. Please check out the PR#350 |
I tried this, but did not work. |
This solves the issue #338
There are cases when the document loads but pdfPage.render method triggers an error as pdfPage is undefined, not having the catch statement triggers a console error.
@FranckFreiburger given you are not maintaining this package since 5-4 months I'm wondering if you can consider requesting some help and include more maintainers.