{"action":"opened","issue":{"url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/352","labels_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/352/labels{/name}","comments_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/352/comments","events_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/352/events","html_url":"https://github.com/Financial-Times/polyfill-service/issues/352","id":62471716,"number":352,"title":"this === undefined: a lot of the polyfills does not work as expected","user":{"login":"monolithed","id":803674,"avatar_url":"https://avatars.githubusercontent.com/u/803674?v=3","gravatar_id":"","url":"https://api.github.com/users/monolithed","html_url":"https://github.com/monolithed","followers_url":"https://api.github.com/users/monolithed/followers","following_url":"https://api.github.com/users/monolithed/following{/other_user}","gists_url":"https://api.github.com/users/monolithed/gists{/gist_id}","starred_url":"https://api.github.com/users/monolithed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monolithed/subscriptions","organizations_url":"https://api.github.com/users/monolithed/orgs","repos_url":"https://api.github.com/users/monolithed/repos","events_url":"https://api.github.com/users/monolithed/events{/privacy}","received_events_url":"https://api.github.com/users/monolithed/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-17T18:02:04Z","updated_at":"2015-03-17T18:02:04Z","closed_at":null,"body":"##### Explanation\r\n\r\n```js\r\n(function () {\r\n   'use strict;\r\n\r\n   (function (global) {\r\n       function Promise () {\r\n                // ...\r\n       }\r\n       global.Promise = Promise; //  Uncaught TypeError: Cannot set property 'Promise' of undefined\r\n   }(this));\r\n}())\r\n```\r\n\r\n##### Problem files\r\n\r\n```\r\n➜ git grep --name-only '[}|)](this)' -- polyfills/*polyfill.js\r\n\r\npolyfills/Event.hashchange/polyfill.js\r\npolyfills/JSON/polyfill.js\r\npolyfills/Navigator.prototype.geolocation/polyfill.js\r\npolyfills/Promise/polyfill.js\r\npolyfills/URL/polyfill.js\r\npolyfills/atob/polyfill.js\r\npolyfills/devicePixelRatio/polyfill.js\r\npolyfills/document.querySelector/polyfill.js\r\npolyfills/getComputedStyle/polyfill.js\r\npolyfills/localStorage/polyfill.js\r\npolyfills/matchMedia/polyfill.js\r\npolyfills/performance.now/polyfill.js\r\npolyfills/requestAnimationFrame/polyfill.js\r\npolyfills/viewport/polyfill.js\r\n```\r\n\r\n*15* polyfills does not work as expected\r\n\r\n\r\n\r\n"}}