{"action":"created","comment":{"url":"https://api.github.com/repos/lodash/lodash/pulls/comments/52796277","id":52796277,"diff_hunk":"@@ -21172,6 +21172,47 @@\n \n   /*--------------------------------------------------------------------------*/\n \n+  QUnit.module('lodash.asArray');\n+\n+  (function() {\n+    var wrapCases = [null, void 0, 1, '', 'ab', 0, {a: 1}, Object('xyz'), NaN];\n+\n+    QUnit.test('should wrap non array items in an array', function(assert) {\n+      assert.expect(wrapCases.length * 2);\n+\n+      _.each(wrapCases, function(val) {\n+        var result = _.asArray(val);\n+        assert.deepEqual(result, [val], 'for value ' + val);\n+        assert.strictEqual(result[0], val, 'should not copy the value');\n+      });\n+    });\n+\n+    QUnit.test('should an array copy if provided array', function(assert) {","path":"test/test.js","position":19,"original_position":19,"commit_id":"4856761115c6d38d44b4f66c224a99e3a3a66e87","original_commit_id":"4856761115c6d38d44b4f66c224a99e3a3a66e87","user":{"login":"jfmengels","id":3869412,"avatar_url":"https://avatars.githubusercontent.com/u/3869412?v=3","gravatar_id":"","url":"https://api.github.com/users/jfmengels","html_url":"https://github.com/jfmengels","followers_url":"https://api.github.com/users/jfmengels/followers","following_url":"https://api.github.com/users/jfmengels/following{/other_user}","gists_url":"https://api.github.com/users/jfmengels/gists{/gist_id}","starred_url":"https://api.github.com/users/jfmengels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jfmengels/subscriptions","organizations_url":"https://api.github.com/users/jfmengels/orgs","repos_url":"https://api.github.com/users/jfmengels/repos","events_url":"https://api.github.com/users/jfmengels/events{/privacy}","received_events_url":"https://api.github.com/users/jfmengels/received_events","type":"User","site_admin":false},"body":"'should an array copy if provided array' --> 'should copy the value if value is an array'\r\n(or should at least be 'should copy an array ...'","created_at":"2016-02-12T20:47:30Z","updated_at":"2016-02-12T20:47:30Z","html_url":"https://github.com/lodash/lodash/pull/1993#discussion_r52796277","pull_request_url":"https://api.github.com/repos/lodash/lodash/pulls/1993","_links":{"self":{"href":"https://api.github.com/repos/lodash/lodash/pulls/comments/52796277"},"html":{"href":"https://github.com/lodash/lodash/pull/1993#discussion_r52796277"},"pull_request":{"href":"https://api.github.com/repos/lodash/lodash/pulls/1993"}}},"pull_request":{"url":"https://api.github.com/repos/lodash/lodash/pulls/1993","id":59225477,"html_url":"https://github.com/lodash/lodash/pull/1993","diff_url":"https://github.com/lodash/lodash/pull/1993.diff","patch_url":"https://github.com/lodash/lodash/pull/1993.patch","issue_url":"https://api.github.com/repos/lodash/lodash/issues/1993","number":1993,"state":"open","locked":false,"title":"Add _.asArray method","user":{"login":"megawac","id":3475472,"avatar_url":"https://avatars.githubusercontent.com/u/3475472?v=3","gravatar_id":"","url":"https://api.github.com/users/megawac","html_url":"https://github.com/megawac","followers_url":"https://api.github.com/users/megawac/followers","following_url":"https://api.github.com/users/megawac/following{/other_user}","gists_url":"https://api.github.com/users/megawac/gists{/gist_id}","starred_url":"https://api.github.com/users/megawac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/megawac/subscriptions","organizations_url":"https://api.github.com/users/megawac/orgs","repos_url":"https://api.github.com/users/megawac/repos","events_url":"https://api.github.com/users/megawac/events{/privacy}","received_events_url":"https://api.github.com/users/megawac/received_events","type":"User","site_admin":false},"body":"i did it!\r\n\r\nHow should `null` and `undefined` be handled? Empty array or `[null]`, `[undefined]`? How about `_.asArray()`?\r\n\r\nResolves #953 ","created_at":"2016-02-12T20:18:46Z","updated_at":"2016-02-12T20:47:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0f92ea3003062a22417c150bfcb710e626d9544e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/lodash/lodash/pulls/1993/commits","review_comments_url":"https://api.github.com/repos/lodash/lodash/pulls/1993/comments","review_comment_url":"https://api.github.com/repos/lodash/lodash/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lodash/lodash/issues/1993/comments","statuses_url":"https://api.github.com/repos/lodash/lodash/statuses/4856761115c6d38d44b4f66c224a99e3a3a66e87","head":{"label":"megawac:asArray","ref":"asArray","sha":"4856761115c6d38d44b4f66c224a99e3a3a66e87","user":{"login":"megawac","id":3475472,"avatar_url":"https://avatars.githubusercontent.com/u/3475472?v=3","gravatar_id":"","url":"https://api.github.com/users/megawac","html_url":"https://github.com/megawac","followers_url":"https://api.github.com/users/megawac/followers","following_url":"https://api.github.com/users/megawac/following{/other_user}","gists_url":"https://api.github.com/users/megawac/gists{/gist_id}","starred_url":"https://api.github.com/users/megawac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/megawac/subscriptions","organizations_url":"https://api.github.com/users/megawac/orgs","repos_url":"https://api.github.com/users/megawac/repos","events_url":"https://api.github.com/users/megawac/events{/privacy}","received_events_url":"https://api.github.com/users/megawac/received_events","type":"User","site_admin":false},"repo":{"id":20787075,"name":"lodash","full_name":"megawac/lodash","owner":{"login":"megawac","id":3475472,"avatar_url":"https://avatars.githubusercontent.com/u/3475472?v=3","gravatar_id":"","url":"https://api.github.com/users/megawac","html_url":"https://github.com/megawac","followers_url":"https://api.github.com/users/megawac/followers","following_url":"https://api.github.com/users/megawac/following{/other_user}","gists_url":"https://api.github.com/users/megawac/gists{/gist_id}","starred_url":"https://api.github.com/users/megawac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/megawac/subscriptions","organizations_url":"https://api.github.com/users/megawac/orgs","repos_url":"https://api.github.com/users/megawac/repos","events_url":"https://api.github.com/users/megawac/events{/privacy}","received_events_url":"https://api.github.com/users/megawac/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/megawac/lodash","description":"A utility library delivering consistency, customization, performance, & extras.","fork":true,"url":"https://api.github.com/repos/megawac/lodash","forks_url":"https://api.github.com/repos/megawac/lodash/forks","keys_url":"https://api.github.com/repos/megawac/lodash/keys{/key_id}","collaborators_url":"https://api.github.com/repos/megawac/lodash/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/megawac/lodash/teams","hooks_url":"https://api.github.com/repos/megawac/lodash/hooks","issue_events_url":"https://api.github.com/repos/megawac/lodash/issues/events{/number}","events_url":"https://api.github.com/repos/megawac/lodash/events","assignees_url":"https://api.github.com/repos/megawac/lodash/assignees{/user}","branches_url":"https://api.github.com/repos/megawac/lodash/branches{/branch}","tags_url":"https://api.github.com/repos/megawac/lodash/tags","blobs_url":"https://api.github.com/repos/megawac/lodash/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/megawac/lodash/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/megawac/lodash/git/refs{/sha}","trees_url":"https://api.github.com/repos/megawac/lodash/git/trees{/sha}","statuses_url":"https://api.github.com/repos/megawac/lodash/statuses/{sha}","languages_url":"https://api.github.com/repos/megawac/lodash/languages","stargazers_url":"https://api.github.com/repos/megawac/lodash/stargazers","contributors_url":"https://api.github.com/repos/megawac/lodash/contributors","subscribers_url":"https://api.github.com/repos/megawac/lodash/subscribers","subscription_url":"https://api.github.com/repos/megawac/lodash/subscription","commits_url":"https://api.github.com/repos/megawac/lodash/commits{/sha}","git_commits_url":"https://api.github.com/repos/megawac/lodash/git/commits{/sha}","comments_url":"https://api.github.com/repos/megawac/lodash/comments{/number}","issue_comment_url":"https://api.github.com/repos/megawac/lodash/issues/comments{/number}","contents_url":"https://api.github.com/repos/megawac/lodash/contents/{+path}","compare_url":"https://api.github.com/repos/megawac/lodash/compare/{base}...{head}","merges_url":"https://api.github.com/repos/megawac/lodash/merges","archive_url":"https://api.github.com/repos/megawac/lodash/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/megawac/lodash/downloads","issues_url":"https://api.github.com/repos/megawac/lodash/issues{/number}","pulls_url":"https://api.github.com/repos/megawac/lodash/pulls{/number}","milestones_url":"https://api.github.com/repos/megawac/lodash/milestones{/number}","notifications_url":"https://api.github.com/repos/megawac/lodash/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/megawac/lodash/labels{/name}","releases_url":"https://api.github.com/repos/megawac/lodash/releases{/id}","deployments_url":"https://api.github.com/repos/megawac/lodash/deployments","created_at":"2014-06-13T00:20:18Z","updated_at":"2014-07-09T14:46:09Z","pushed_at":"2016-02-12T20:20:23Z","git_url":"git://github.com/megawac/lodash.git","ssh_url":"git@github.com:megawac/lodash.git","clone_url":"https://github.com/megawac/lodash.git","svn_url":"https://github.com/megawac/lodash","homepage":"http://lodash.com/","size":35163,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"lodash:master","ref":"master","sha":"d5e1d7b3c2445d9e161028a1f1e25a3006c0eb89","user":{"login":"lodash","id":2565403,"avatar_url":"https://avatars.githubusercontent.com/u/2565403?v=3","gravatar_id":"","url":"https://api.github.com/users/lodash","html_url":"https://github.com/lodash","followers_url":"https://api.github.com/users/lodash/followers","following_url":"https://api.github.com/users/lodash/following{/other_user}","gists_url":"https://api.github.com/users/lodash/gists{/gist_id}","starred_url":"https://api.github.com/users/lodash/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lodash/subscriptions","organizations_url":"https://api.github.com/users/lodash/orgs","repos_url":"https://api.github.com/users/lodash/repos","events_url":"https://api.github.com/users/lodash/events{/privacy}","received_events_url":"https://api.github.com/users/lodash/received_events","type":"Organization","site_admin":false},"repo":{"id":3955647,"name":"lodash","full_name":"lodash/lodash","owner":{"login":"lodash","id":2565403,"avatar_url":"https://avatars.githubusercontent.com/u/2565403?v=3","gravatar_id":"","url":"https://api.github.com/users/lodash","html_url":"https://github.com/lodash","followers_url":"https://api.github.com/users/lodash/followers","following_url":"https://api.github.com/users/lodash/following{/other_user}","gists_url":"https://api.github.com/users/lodash/gists{/gist_id}","starred_url":"https://api.github.com/users/lodash/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lodash/subscriptions","organizations_url":"https://api.github.com/users/lodash/orgs","repos_url":"https://api.github.com/users/lodash/repos","events_url":"https://api.github.com/users/lodash/events{/privacy}","received_events_url":"https://api.github.com/users/lodash/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/lodash/lodash","description":"A modern JavaScript utility library delivering modularity, performance, & extras.","fork":false,"url":"https://api.github.com/repos/lodash/lodash","forks_url":"https://api.github.com/repos/lodash/lodash/forks","keys_url":"https://api.github.com/repos/lodash/lodash/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lodash/lodash/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lodash/lodash/teams","hooks_url":"https://api.github.com/repos/lodash/lodash/hooks","issue_events_url":"https://api.github.com/repos/lodash/lodash/issues/events{/number}","events_url":"https://api.github.com/repos/lodash/lodash/events","assignees_url":"https://api.github.com/repos/lodash/lodash/assignees{/user}","branches_url":"https://api.github.com/repos/lodash/lodash/branches{/branch}","tags_url":"https://api.github.com/repos/lodash/lodash/tags","blobs_url":"https://api.github.com/repos/lodash/lodash/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lodash/lodash/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lodash/lodash/git/refs{/sha}","trees_url":"https://api.github.com/repos/lodash/lodash/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lodash/lodash/statuses/{sha}","languages_url":"https://api.github.com/repos/lodash/lodash/languages","stargazers_url":"https://api.github.com/repos/lodash/lodash/stargazers","contributors_url":"https://api.github.com/repos/lodash/lodash/contributors","subscribers_url":"https://api.github.com/repos/lodash/lodash/subscribers","subscription_url":"https://api.github.com/repos/lodash/lodash/subscription","commits_url":"https://api.github.com/repos/lodash/lodash/commits{/sha}","git_commits_url":"https://api.github.com/repos/lodash/lodash/git/commits{/sha}","comments_url":"https://api.github.com/repos/lodash/lodash/comments{/number}","issue_comment_url":"https://api.github.com/repos/lodash/lodash/issues/comments{/number}","contents_url":"https://api.github.com/repos/lodash/lodash/contents/{+path}","compare_url":"https://api.github.com/repos/lodash/lodash/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lodash/lodash/merges","archive_url":"https://api.github.com/repos/lodash/lodash/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lodash/lodash/downloads","issues_url":"https://api.github.com/repos/lodash/lodash/issues{/number}","pulls_url":"https://api.github.com/repos/lodash/lodash/pulls{/number}","milestones_url":"https://api.github.com/repos/lodash/lodash/milestones{/number}","notifications_url":"https://api.github.com/repos/lodash/lodash/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lodash/lodash/labels{/name}","releases_url":"https://api.github.com/repos/lodash/lodash/releases{/id}","deployments_url":"https://api.github.com/repos/lodash/lodash/deployments","created_at":"2012-04-07T04:11:46Z","updated_at":"2016-02-12T19:58:10Z","pushed_at":"2016-02-12T20:20:23Z","git_url":"git://github.com/lodash/lodash.git","ssh_url":"git@github.com:lodash/lodash.git","clone_url":"https://github.com/lodash/lodash.git","svn_url":"https://github.com/lodash/lodash","homepage":"https://lodash.com/","size":121469,"stargazers_count":14584,"watchers_count":14584,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1326,"mirror_url":null,"open_issues_count":1,"forks":1326,"open_issues":1,"watchers":14584,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lodash/lodash/pulls/1993"},"html":{"href":"https://github.com/lodash/lodash/pull/1993"},"issue":{"href":"https://api.github.com/repos/lodash/lodash/issues/1993"},"comments":{"href":"https://api.github.com/repos/lodash/lodash/issues/1993/comments"},"review_comments":{"href":"https://api.github.com/repos/lodash/lodash/pulls/1993/comments"},"review_comment":{"href":"https://api.github.com/repos/lodash/lodash/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lodash/lodash/pulls/1993/commits"},"statuses":{"href":"https://api.github.com/repos/lodash/lodash/statuses/4856761115c6d38d44b4f66c224a99e3a3a66e87"}}}}