{"action":"created","comment":{"url":"https://api.github.com/repos/interlockjs/interlock/pulls/comments/37341145","id":37341145,"diff_hunk":"@@ -71,27 +51,29 @@ function normalizeOpts (options, ns) {\n  *                                            attempting to resolve that require-string.\n  * @param   {String}    options.ns            The namespace for the build.  If omitted, the value\n  *                                            will be borrowed from `name` in package.json.\n+ * @param   {Boolean}   options.sourceMaps    Emit source maps with the bundles\n+ * @param   {Array}     options.plugins       An Array of interlock Plugins\n+ * @param   {Boolean}   options.includeComments     Include comments in the compiled bundles\n+ * @param   {String}    options.implicitBundleDest  The location to emit shared dependency bundles\n  */\n export default function Interlock (options) {\n-  const hasEntries = !!(options.entry && Object.keys(options.entry).length);\n-  const hasSplits = !!(options.split && Object.keys(options.entry).length);\n-\n-  if (!hasEntries && !hasSplits) {\n-    throw new Error(\"You must define at least one entry or split point.\");\n-  }\n-  if (!_.isString(options.srcRoot)) {\n-    throw new Error(\"Must define a project srcRoot\");\n-  }\n-\n-  let ns;\n-  try {\n-    ns = require(path.join(options.srcRoot, \"./package.json\")).name;\n-  } catch (e) {\n-    throw new Error(\"Invalid project root - cannot find package.json\");\n-  }\n+  Joi.validate(options || {}, constructorInputSchema, (err, value) => {\n+    if (err) { throw err; }","path":"lib/index.js","position":76,"original_position":76,"commit_id":"9000ffe25e6425f6ef381b864f6040230f7a0907","original_commit_id":"9000ffe25e6425f6ef381b864f6040230f7a0907","user":{"login":"divmain","id":5016978,"avatar_url":"https://avatars.githubusercontent.com/u/5016978?v=3","gravatar_id":"","url":"https://api.github.com/users/divmain","html_url":"https://github.com/divmain","followers_url":"https://api.github.com/users/divmain/followers","following_url":"https://api.github.com/users/divmain/following{/other_user}","gists_url":"https://api.github.com/users/divmain/gists{/gist_id}","starred_url":"https://api.github.com/users/divmain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/divmain/subscriptions","organizations_url":"https://api.github.com/users/divmain/orgs","repos_url":"https://api.github.com/users/divmain/repos","events_url":"https://api.github.com/users/divmain/events{/privacy}","received_events_url":"https://api.github.com/users/divmain/received_events","type":"User","site_admin":false},"body":"Is this callback invoked synchronously?","created_at":"2015-08-18T19:18:35Z","updated_at":"2015-08-18T19:18:35Z","html_url":"https://github.com/interlockjs/interlock/pull/24#discussion_r37341145","pull_request_url":"https://api.github.com/repos/interlockjs/interlock/pulls/24","_links":{"self":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/comments/37341145"},"html":{"href":"https://github.com/interlockjs/interlock/pull/24#discussion_r37341145"},"pull_request":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/24"}}},"pull_request":{"url":"https://api.github.com/repos/interlockjs/interlock/pulls/24","id":41510013,"html_url":"https://github.com/interlockjs/interlock/pull/24","diff_url":"https://github.com/interlockjs/interlock/pull/24.diff","patch_url":"https://github.com/interlockjs/interlock/pull/24.patch","issue_url":"https://api.github.com/repos/interlockjs/interlock/issues/24","number":24,"state":"open","locked":false,"title":"[WIP] input validation","user":{"login":"baer","id":940667,"avatar_url":"https://avatars.githubusercontent.com/u/940667?v=3","gravatar_id":"","url":"https://api.github.com/users/baer","html_url":"https://github.com/baer","followers_url":"https://api.github.com/users/baer/followers","following_url":"https://api.github.com/users/baer/following{/other_user}","gists_url":"https://api.github.com/users/baer/gists{/gist_id}","starred_url":"https://api.github.com/users/baer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baer/subscriptions","organizations_url":"https://api.github.com/users/baer/orgs","repos_url":"https://api.github.com/users/baer/repos","events_url":"https://api.github.com/users/baer/events{/privacy}","received_events_url":"https://api.github.com/users/baer/received_events","type":"User","site_admin":false},"body":"PR to validate input for the Interlock constructor (#19)","created_at":"2015-08-03T21:07:56Z","updated_at":"2015-08-18T19:18:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4cbf636cebdd0b51d5d16853c15b70725b1c94f7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/interlockjs/interlock/pulls/24/commits","review_comments_url":"https://api.github.com/repos/interlockjs/interlock/pulls/24/comments","review_comment_url":"https://api.github.com/repos/interlockjs/interlock/pulls/comments{/number}","comments_url":"https://api.github.com/repos/interlockjs/interlock/issues/24/comments","statuses_url":"https://api.github.com/repos/interlockjs/interlock/statuses/9000ffe25e6425f6ef381b864f6040230f7a0907","head":{"label":"interlockjs:feature/input-validation","ref":"feature/input-validation","sha":"9000ffe25e6425f6ef381b864f6040230f7a0907","user":{"login":"interlockjs","id":13458904,"avatar_url":"https://avatars.githubusercontent.com/u/13458904?v=3","gravatar_id":"","url":"https://api.github.com/users/interlockjs","html_url":"https://github.com/interlockjs","followers_url":"https://api.github.com/users/interlockjs/followers","following_url":"https://api.github.com/users/interlockjs/following{/other_user}","gists_url":"https://api.github.com/users/interlockjs/gists{/gist_id}","starred_url":"https://api.github.com/users/interlockjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interlockjs/subscriptions","organizations_url":"https://api.github.com/users/interlockjs/orgs","repos_url":"https://api.github.com/users/interlockjs/repos","events_url":"https://api.github.com/users/interlockjs/events{/privacy}","received_events_url":"https://api.github.com/users/interlockjs/received_events","type":"Organization","site_admin":false},"repo":{"id":35057998,"name":"interlock","full_name":"interlockjs/interlock","owner":{"login":"interlockjs","id":13458904,"avatar_url":"https://avatars.githubusercontent.com/u/13458904?v=3","gravatar_id":"","url":"https://api.github.com/users/interlockjs","html_url":"https://github.com/interlockjs","followers_url":"https://api.github.com/users/interlockjs/followers","following_url":"https://api.github.com/users/interlockjs/following{/other_user}","gists_url":"https://api.github.com/users/interlockjs/gists{/gist_id}","starred_url":"https://api.github.com/users/interlockjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interlockjs/subscriptions","organizations_url":"https://api.github.com/users/interlockjs/orgs","repos_url":"https://api.github.com/users/interlockjs/repos","events_url":"https://api.github.com/users/interlockjs/events{/privacy}","received_events_url":"https://api.github.com/users/interlockjs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/interlockjs/interlock","description":"Git-inspired JS bundler/loader.","fork":false,"url":"https://api.github.com/repos/interlockjs/interlock","forks_url":"https://api.github.com/repos/interlockjs/interlock/forks","keys_url":"https://api.github.com/repos/interlockjs/interlock/keys{/key_id}","collaborators_url":"https://api.github.com/repos/interlockjs/interlock/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/interlockjs/interlock/teams","hooks_url":"https://api.github.com/repos/interlockjs/interlock/hooks","issue_events_url":"https://api.github.com/repos/interlockjs/interlock/issues/events{/number}","events_url":"https://api.github.com/repos/interlockjs/interlock/events","assignees_url":"https://api.github.com/repos/interlockjs/interlock/assignees{/user}","branches_url":"https://api.github.com/repos/interlockjs/interlock/branches{/branch}","tags_url":"https://api.github.com/repos/interlockjs/interlock/tags","blobs_url":"https://api.github.com/repos/interlockjs/interlock/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/interlockjs/interlock/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/interlockjs/interlock/git/refs{/sha}","trees_url":"https://api.github.com/repos/interlockjs/interlock/git/trees{/sha}","statuses_url":"https://api.github.com/repos/interlockjs/interlock/statuses/{sha}","languages_url":"https://api.github.com/repos/interlockjs/interlock/languages","stargazers_url":"https://api.github.com/repos/interlockjs/interlock/stargazers","contributors_url":"https://api.github.com/repos/interlockjs/interlock/contributors","subscribers_url":"https://api.github.com/repos/interlockjs/interlock/subscribers","subscription_url":"https://api.github.com/repos/interlockjs/interlock/subscription","commits_url":"https://api.github.com/repos/interlockjs/interlock/commits{/sha}","git_commits_url":"https://api.github.com/repos/interlockjs/interlock/git/commits{/sha}","comments_url":"https://api.github.com/repos/interlockjs/interlock/comments{/number}","issue_comment_url":"https://api.github.com/repos/interlockjs/interlock/issues/comments{/number}","contents_url":"https://api.github.com/repos/interlockjs/interlock/contents/{+path}","compare_url":"https://api.github.com/repos/interlockjs/interlock/compare/{base}...{head}","merges_url":"https://api.github.com/repos/interlockjs/interlock/merges","archive_url":"https://api.github.com/repos/interlockjs/interlock/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/interlockjs/interlock/downloads","issues_url":"https://api.github.com/repos/interlockjs/interlock/issues{/number}","pulls_url":"https://api.github.com/repos/interlockjs/interlock/pulls{/number}","milestones_url":"https://api.github.com/repos/interlockjs/interlock/milestones{/number}","notifications_url":"https://api.github.com/repos/interlockjs/interlock/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/interlockjs/interlock/labels{/name}","releases_url":"https://api.github.com/repos/interlockjs/interlock/releases{/id}","created_at":"2015-05-04T20:33:50Z","updated_at":"2015-08-06T17:41:35Z","pushed_at":"2015-08-18T07:15:09Z","git_url":"git://github.com/interlockjs/interlock.git","ssh_url":"git@github.com:interlockjs/interlock.git","clone_url":"https://github.com/interlockjs/interlock.git","svn_url":"https://github.com/interlockjs/interlock","homepage":"","size":846,"stargazers_count":7,"watchers_count":7,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":10,"forks":4,"open_issues":10,"watchers":7,"default_branch":"master"}},"base":{"label":"interlockjs:master","ref":"master","sha":"3a0d3874b72829807031848ed47a26b0bebf0ee2","user":{"login":"interlockjs","id":13458904,"avatar_url":"https://avatars.githubusercontent.com/u/13458904?v=3","gravatar_id":"","url":"https://api.github.com/users/interlockjs","html_url":"https://github.com/interlockjs","followers_url":"https://api.github.com/users/interlockjs/followers","following_url":"https://api.github.com/users/interlockjs/following{/other_user}","gists_url":"https://api.github.com/users/interlockjs/gists{/gist_id}","starred_url":"https://api.github.com/users/interlockjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interlockjs/subscriptions","organizations_url":"https://api.github.com/users/interlockjs/orgs","repos_url":"https://api.github.com/users/interlockjs/repos","events_url":"https://api.github.com/users/interlockjs/events{/privacy}","received_events_url":"https://api.github.com/users/interlockjs/received_events","type":"Organization","site_admin":false},"repo":{"id":35057998,"name":"interlock","full_name":"interlockjs/interlock","owner":{"login":"interlockjs","id":13458904,"avatar_url":"https://avatars.githubusercontent.com/u/13458904?v=3","gravatar_id":"","url":"https://api.github.com/users/interlockjs","html_url":"https://github.com/interlockjs","followers_url":"https://api.github.com/users/interlockjs/followers","following_url":"https://api.github.com/users/interlockjs/following{/other_user}","gists_url":"https://api.github.com/users/interlockjs/gists{/gist_id}","starred_url":"https://api.github.com/users/interlockjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interlockjs/subscriptions","organizations_url":"https://api.github.com/users/interlockjs/orgs","repos_url":"https://api.github.com/users/interlockjs/repos","events_url":"https://api.github.com/users/interlockjs/events{/privacy}","received_events_url":"https://api.github.com/users/interlockjs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/interlockjs/interlock","description":"Git-inspired JS bundler/loader.","fork":false,"url":"https://api.github.com/repos/interlockjs/interlock","forks_url":"https://api.github.com/repos/interlockjs/interlock/forks","keys_url":"https://api.github.com/repos/interlockjs/interlock/keys{/key_id}","collaborators_url":"https://api.github.com/repos/interlockjs/interlock/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/interlockjs/interlock/teams","hooks_url":"https://api.github.com/repos/interlockjs/interlock/hooks","issue_events_url":"https://api.github.com/repos/interlockjs/interlock/issues/events{/number}","events_url":"https://api.github.com/repos/interlockjs/interlock/events","assignees_url":"https://api.github.com/repos/interlockjs/interlock/assignees{/user}","branches_url":"https://api.github.com/repos/interlockjs/interlock/branches{/branch}","tags_url":"https://api.github.com/repos/interlockjs/interlock/tags","blobs_url":"https://api.github.com/repos/interlockjs/interlock/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/interlockjs/interlock/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/interlockjs/interlock/git/refs{/sha}","trees_url":"https://api.github.com/repos/interlockjs/interlock/git/trees{/sha}","statuses_url":"https://api.github.com/repos/interlockjs/interlock/statuses/{sha}","languages_url":"https://api.github.com/repos/interlockjs/interlock/languages","stargazers_url":"https://api.github.com/repos/interlockjs/interlock/stargazers","contributors_url":"https://api.github.com/repos/interlockjs/interlock/contributors","subscribers_url":"https://api.github.com/repos/interlockjs/interlock/subscribers","subscription_url":"https://api.github.com/repos/interlockjs/interlock/subscription","commits_url":"https://api.github.com/repos/interlockjs/interlock/commits{/sha}","git_commits_url":"https://api.github.com/repos/interlockjs/interlock/git/commits{/sha}","comments_url":"https://api.github.com/repos/interlockjs/interlock/comments{/number}","issue_comment_url":"https://api.github.com/repos/interlockjs/interlock/issues/comments{/number}","contents_url":"https://api.github.com/repos/interlockjs/interlock/contents/{+path}","compare_url":"https://api.github.com/repos/interlockjs/interlock/compare/{base}...{head}","merges_url":"https://api.github.com/repos/interlockjs/interlock/merges","archive_url":"https://api.github.com/repos/interlockjs/interlock/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/interlockjs/interlock/downloads","issues_url":"https://api.github.com/repos/interlockjs/interlock/issues{/number}","pulls_url":"https://api.github.com/repos/interlockjs/interlock/pulls{/number}","milestones_url":"https://api.github.com/repos/interlockjs/interlock/milestones{/number}","notifications_url":"https://api.github.com/repos/interlockjs/interlock/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/interlockjs/interlock/labels{/name}","releases_url":"https://api.github.com/repos/interlockjs/interlock/releases{/id}","created_at":"2015-05-04T20:33:50Z","updated_at":"2015-08-06T17:41:35Z","pushed_at":"2015-08-18T07:15:09Z","git_url":"git://github.com/interlockjs/interlock.git","ssh_url":"git@github.com:interlockjs/interlock.git","clone_url":"https://github.com/interlockjs/interlock.git","svn_url":"https://github.com/interlockjs/interlock","homepage":"","size":846,"stargazers_count":7,"watchers_count":7,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":10,"forks":4,"open_issues":10,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/24"},"html":{"href":"https://github.com/interlockjs/interlock/pull/24"},"issue":{"href":"https://api.github.com/repos/interlockjs/interlock/issues/24"},"comments":{"href":"https://api.github.com/repos/interlockjs/interlock/issues/24/comments"},"review_comments":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/24/comments"},"review_comment":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/interlockjs/interlock/pulls/24/commits"},"statuses":{"href":"https://api.github.com/repos/interlockjs/interlock/statuses/9000ffe25e6425f6ef381b864f6040230f7a0907"}}}}