{"action":"created","issue":{"url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/2","repository_url":"https://api.github.com/repos/tricknotes/npm-git-info","labels_url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/2/comments","events_url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/2/events","html_url":"https://github.com/tricknotes/npm-git-info/pull/2","id":137809567,"number":2,"title":"Fix ref for `npm install xx@version` installed modules for npm v2","user":{"login":"pangratz","id":341877,"avatar_url":"https://avatars.githubusercontent.com/u/341877?v=3","gravatar_id":"","url":"https://api.github.com/users/pangratz","html_url":"https://github.com/pangratz","followers_url":"https://api.github.com/users/pangratz/followers","following_url":"https://api.github.com/users/pangratz/following{/other_user}","gists_url":"https://api.github.com/users/pangratz/gists{/gist_id}","starred_url":"https://api.github.com/users/pangratz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pangratz/subscriptions","organizations_url":"https://api.github.com/users/pangratz/orgs","repos_url":"https://api.github.com/users/pangratz/repos","events_url":"https://api.github.com/users/pangratz/events{/privacy}","received_events_url":"https://api.github.com/users/pangratz/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-03-02T08:44:30Z","updated_at":"2016-03-02T11:07:47Z","closed_at":"2016-03-02T11:06:20Z","pull_request":{"url":"https://api.github.com/repos/tricknotes/npm-git-info/pulls/2","html_url":"https://github.com/tricknotes/npm-git-info/pull/2","diff_url":"https://github.com/tricknotes/npm-git-info/pull/2.diff","patch_url":"https://github.com/tricknotes/npm-git-info/pull/2.patch"},"body":"It looks like the `package.json` of a dependency installed via npm v2 has\r\nno `package._requested`, which needs to be considered when the ref is\r\ncalculated.\r\n\r\n---\r\n\r\nI hope that this fixes the correct calculation for `info.ref` once and for all :pensive: I am not too familiar with the different formats of `package.json` for the different `npm` versions. Also, I am not sure if this is dependent on the `node` version too. The `package.json` in this PR is the result of using a different `npm` version which shows that there is no `package._requested` present."},"comment":{"url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/comments/191190007","html_url":"https://github.com/tricknotes/npm-git-info/pull/2#issuecomment-191190007","issue_url":"https://api.github.com/repos/tricknotes/npm-git-info/issues/2","id":191190007,"user":{"login":"tricknotes","id":290782,"avatar_url":"https://avatars.githubusercontent.com/u/290782?v=3","gravatar_id":"","url":"https://api.github.com/users/tricknotes","html_url":"https://github.com/tricknotes","followers_url":"https://api.github.com/users/tricknotes/followers","following_url":"https://api.github.com/users/tricknotes/following{/other_user}","gists_url":"https://api.github.com/users/tricknotes/gists{/gist_id}","starred_url":"https://api.github.com/users/tricknotes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tricknotes/subscriptions","organizations_url":"https://api.github.com/users/tricknotes/orgs","repos_url":"https://api.github.com/users/tricknotes/repos","events_url":"https://api.github.com/users/tricknotes/events{/privacy}","received_events_url":"https://api.github.com/users/tricknotes/received_events","type":"User","site_admin":false},"created_at":"2016-03-02T11:07:47Z","updated_at":"2016-03-02T11:07:47Z","body":"I just released `1.0.2` :shipit: \r\n"}}