{"action":"created","issue":{"url":"https://api.github.com/repos/almende/vis/issues/1052","labels_url":"https://api.github.com/repos/almende/vis/issues/1052/labels{/name}","comments_url":"https://api.github.com/repos/almende/vis/issues/1052/comments","events_url":"https://api.github.com/repos/almende/vis/issues/1052/events","html_url":"https://github.com/almende/vis/pull/1052","id":92444881,"number":1052,"title":"Use hasOwnProperty in Network.prototype._isMoving","user":{"login":"janrotter","id":12612258,"avatar_url":"https://avatars.githubusercontent.com/u/12612258?v=3","gravatar_id":"","url":"https://api.github.com/users/janrotter","html_url":"https://github.com/janrotter","followers_url":"https://api.github.com/users/janrotter/followers","following_url":"https://api.github.com/users/janrotter/following{/other_user}","gists_url":"https://api.github.com/users/janrotter/gists{/gist_id}","starred_url":"https://api.github.com/users/janrotter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janrotter/subscriptions","organizations_url":"https://api.github.com/users/janrotter/orgs","repos_url":"https://api.github.com/users/janrotter/repos","events_url":"https://api.github.com/users/janrotter/events{/privacy}","received_events_url":"https://api.github.com/users/janrotter/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-07-01T17:47:48Z","updated_at":"2015-07-01T20:35:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/almende/vis/pulls/1052","html_url":"https://github.com/almende/vis/pull/1052","diff_url":"https://github.com/almende/vis/pull/1052.diff","patch_url":"https://github.com/almende/vis/pull/1052.patch"},"body":""},"comment":{"url":"https://api.github.com/repos/almende/vis/issues/comments/117817888","html_url":"https://github.com/almende/vis/pull/1052#issuecomment-117817888","issue_url":"https://api.github.com/repos/almende/vis/issues/1052","id":117817888,"user":{"login":"AlexDM0","id":5363277,"avatar_url":"https://avatars.githubusercontent.com/u/5363277?v=3","gravatar_id":"","url":"https://api.github.com/users/AlexDM0","html_url":"https://github.com/AlexDM0","followers_url":"https://api.github.com/users/AlexDM0/followers","following_url":"https://api.github.com/users/AlexDM0/following{/other_user}","gists_url":"https://api.github.com/users/AlexDM0/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexDM0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexDM0/subscriptions","organizations_url":"https://api.github.com/users/AlexDM0/orgs","repos_url":"https://api.github.com/users/AlexDM0/repos","events_url":"https://api.github.com/users/AlexDM0/events{/privacy}","received_events_url":"https://api.github.com/users/AlexDM0/received_events","type":"User","site_admin":false},"created_at":"2015-07-01T20:35:38Z","updated_at":"2015-07-01T20:35:38Z","body":"Hi Jan,\n\nWe actually use the undefined check a lot. HasOwnProperty is a lot more expensive computationally and I don't really want to change it for this one case of bad JavaScript practice. Don't touch what's not yours ;). \n\nIs it required to molest the Object?\n\nRegards\n\n\n\n> On 1 jul. 2015, at 22:06, janrotter <notifications@github.com> wrote:\n> \n> Hi Alex,\n> I've encountered a code where some additional properties had been added to the Object.prototype and they were considered (wrongly) as node id's in the _isMoving function.\n> \n> I've noticed, that in the rest of the Network.js the hasOwnProperty check is commonly used, so such situations won't occur. My commit changes the _isMoving function to follow that convention.\n> \n> I failed to find any other checks for nodes[id] !== undefined or a reason to perform that check.\n> \n> Best regards,\n> Jan\n> \n> —\n> Reply to this email directly or view it on GitHub.\n> \n"}}