{"action":"created","issue":{"url":"https://api.github.com/repos/angular/angular.js/issues/10950","labels_url":"https://api.github.com/repos/angular/angular.js/issues/10950/labels{/name}","comments_url":"https://api.github.com/repos/angular/angular.js/issues/10950/comments","events_url":"https://api.github.com/repos/angular/angular.js/issues/10950/events","html_url":"https://github.com/angular/angular.js/pull/10950","id":56449613,"number":10950,"title":"Add `undefined` as in/outputs of to/fromJson.","user":{"login":"wesalvaro","id":13286,"avatar_url":"https://avatars.githubusercontent.com/u/13286?v=3","gravatar_id":"","url":"https://api.github.com/users/wesalvaro","html_url":"https://github.com/wesalvaro","followers_url":"https://api.github.com/users/wesalvaro/followers","following_url":"https://api.github.com/users/wesalvaro/following{/other_user}","gists_url":"https://api.github.com/users/wesalvaro/gists{/gist_id}","starred_url":"https://api.github.com/users/wesalvaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wesalvaro/subscriptions","organizations_url":"https://api.github.com/users/wesalvaro/orgs","repos_url":"https://api.github.com/users/wesalvaro/repos","events_url":"https://api.github.com/users/wesalvaro/events{/privacy}","received_events_url":"https://api.github.com/users/wesalvaro/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/angular/angular.js/labels/cla:%20yes","name":"cla: yes","color":"bfe5bf"},{"url":"https://api.github.com/repos/angular/angular.js/labels/component:%20misc%20core","name":"component: misc core","color":"fef2c0"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/angular/angular.js/milestones/27","labels_url":"https://api.github.com/repos/angular/angular.js/milestones/27/labels","id":489171,"number":27,"title":"Backlog","description":"Holds the backlog of issues and pull requests that have been triaged.\r\n\r\nBefore assigning items to this milestone they should be labelled, at the very least with the correct \"type\" label (i.e. \"issue\", \"pr\", \"bug\", \"regression\", \"chore\", \"docs\", etc).  Preferably you should also check for duplicate issues/PRs, note CLA status and assign \"complexity\" and \"impact\" labels too.","creator":{"login":"IgorMinar","id":216296,"avatar_url":"https://avatars.githubusercontent.com/u/216296?v=3","gravatar_id":"","url":"https://api.github.com/users/IgorMinar","html_url":"https://github.com/IgorMinar","followers_url":"https://api.github.com/users/IgorMinar/followers","following_url":"https://api.github.com/users/IgorMinar/following{/other_user}","gists_url":"https://api.github.com/users/IgorMinar/gists{/gist_id}","starred_url":"https://api.github.com/users/IgorMinar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IgorMinar/subscriptions","organizations_url":"https://api.github.com/users/IgorMinar/orgs","repos_url":"https://api.github.com/users/IgorMinar/repos","events_url":"https://api.github.com/users/IgorMinar/events{/privacy}","received_events_url":"https://api.github.com/users/IgorMinar/received_events","type":"User","site_admin":false},"open_issues":725,"closed_issues":741,"state":"open","created_at":"2013-11-18T23:30:35Z","updated_at":"2015-02-04T10:06:47Z","due_on":null,"closed_at":null},"comments":2,"created_at":"2015-02-03T22:41:26Z","updated_at":"2015-02-04T11:06:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/angular/angular.js/pulls/10950","html_url":"https://github.com/angular/angular.js/pull/10950","diff_url":"https://github.com/angular/angular.js/pull/10950.diff","patch_url":"https://github.com/angular/angular.js/pull/10950.patch"},"body":"It is acceptable to pass and possible to receive `undefined` when using the `angular.toJson` and `angular.fromJson` methods."},"comment":{"url":"https://api.github.com/repos/angular/angular.js/issues/comments/72837082","html_url":"https://github.com/angular/angular.js/pull/10950#issuecomment-72837082","issue_url":"https://api.github.com/repos/angular/angular.js/issues/10950","id":72837082,"user":{"login":"wesalvaro","id":13286,"avatar_url":"https://avatars.githubusercontent.com/u/13286?v=3","gravatar_id":"","url":"https://api.github.com/users/wesalvaro","html_url":"https://github.com/wesalvaro","followers_url":"https://api.github.com/users/wesalvaro/followers","following_url":"https://api.github.com/users/wesalvaro/following{/other_user}","gists_url":"https://api.github.com/users/wesalvaro/gists{/gist_id}","starred_url":"https://api.github.com/users/wesalvaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wesalvaro/subscriptions","organizations_url":"https://api.github.com/users/wesalvaro/orgs","repos_url":"https://api.github.com/users/wesalvaro/repos","events_url":"https://api.github.com/users/wesalvaro/events{/privacy}","received_events_url":"https://api.github.com/users/wesalvaro/received_events","type":"User","site_admin":false},"created_at":"2015-02-04T11:06:38Z","updated_at":"2015-02-04T11:06:38Z","body":"I don't think I would change it to an optional parameter. If you call it without an argument, nothing will ever happen; that's the wrong way to call it. However, you can certainly pass in `undefined`, in which case you'll get `undefined` back. There are a variety of scenarios where that would be reasonable. I'll add some tests if this will be merged, no problem."}}