Skip to content
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

Fixes WeakMap polyfill (and improves PDFWorker port check). #8522

Merged
merged 1 commit into from
Jun 13, 2017

Conversation

yurydelendik
Copy link
Contributor

Regressed on IE9 after #8508 -- WeakMap polyfill did not work per spec.

@yurydelendik
Copy link
Contributor Author

/botio-linux preview

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_preview from @yurydelendik received. Current queue size: 0

Live output at: http://54.67.70.0:8877/1bc3f4f2940a38f/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/1bc3f4f2940a38f/output.txt

Total script time: 2.18 mins

Published

@yurydelendik
Copy link
Contributor Author

/botio unittest

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_unittest from @yurydelendik received. Current queue size: 0

Live output at: http://54.67.70.0:8877/7edf8e9d8d1a39d/output.txt

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_unittest from @yurydelendik received. Current queue size: 0

Live output at: http://54.215.176.217:8877/eda74b7cb882481/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/7edf8e9d8d1a39d/output.txt

Total script time: 2.36 mins

  • Unit Tests: Passed

Copy link
Collaborator

@Snuffleupagus Snuffleupagus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thank you!

@@ -1176,10 +1176,13 @@ PDFJS.compatibilityChecked = true;
}
WeakMap.prototype = {
has(obj) {
if (typeof obj !== 'object' || obj === null) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless I'm misunderstanding the examples at https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap#Examples, it appears that it should also work if obj is of type function.
So, do we need to add a typeof obj !== 'function' check as well here?

@pdfjsbot
Copy link

From: Bot.io (Windows)


Success

Full output at http://54.215.176.217:8877/eda74b7cb882481/output.txt

Total script time: 11.68 mins

  • Unit Tests: Passed

@yurydelendik
Copy link
Contributor Author

/botio-linux preview

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_preview from @yurydelendik received. Current queue size: 0

Live output at: http://54.67.70.0:8877/8a6501fafbd1f0e/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/8a6501fafbd1f0e/output.txt

Total script time: 2.21 mins

Published

@yurydelendik yurydelendik merged commit 82f3145 into mozilla:master Jun 13, 2017
movsb pushed a commit to movsb/pdf.js that referenced this pull request Jul 14, 2018
Fixes WeakMap polyfill (and improves PDFWorker port check).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants