{"action":"created","comment":{"url":"https://api.github.com/repos/rendrjs/rendr/pulls/comments/25913713","id":25913713,"diff_hunk":"@@ -166,7 +168,21 @@ _.extend(BaseRouter.prototype, Backbone.Events, {\n             callback.apply(this, arguments);\n           }\n         }\n-        realAction.call(this, params, next);\n+        // in AMD environment realAction is the string containing path to the controller\n+        // which will be loaded async (might be preloaded)\n+        // Only used in AMD environment\n+        if (isAMDEnvironment) {\n+          requireAMD([realAction], function(controller) {","path":"shared/base/router.js","position":15,"original_position":15,"commit_id":"8754d98f3340c5cff93117488c394d51510df7dc","original_commit_id":"8754d98f3340c5cff93117488c394d51510df7dc","user":{"login":"alexindigo","id":127063,"avatar_url":"https://avatars.githubusercontent.com/u/127063?v=3","gravatar_id":"","url":"https://api.github.com/users/alexindigo","html_url":"https://github.com/alexindigo","followers_url":"https://api.github.com/users/alexindigo/followers","following_url":"https://api.github.com/users/alexindigo/following{/other_user}","gists_url":"https://api.github.com/users/alexindigo/gists{/gist_id}","starred_url":"https://api.github.com/users/alexindigo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexindigo/subscriptions","organizations_url":"https://api.github.com/users/alexindigo/orgs","repos_url":"https://api.github.com/users/alexindigo/repos","events_url":"https://api.github.com/users/alexindigo/events{/privacy}","received_events_url":"https://api.github.com/users/alexindigo/received_events","type":"User","site_admin":false},"body":"Then let's check for the variable type, which will protect us from changes down the road\r\nand will allow more flexible treatment of AMD environment on the server.","created_at":"2015-03-05T23:42:36Z","updated_at":"2015-03-05T23:42:36Z","html_url":"https://github.com/rendrjs/rendr/pull/448#discussion_r25913713","pull_request_url":"https://api.github.com/repos/rendrjs/rendr/pulls/448","_links":{"self":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/comments/25913713"},"html":{"href":"https://github.com/rendrjs/rendr/pull/448#discussion_r25913713"},"pull_request":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/448"}}},"pull_request":{"url":"https://api.github.com/repos/rendrjs/rendr/pulls/448","id":30521919,"html_url":"https://github.com/rendrjs/rendr/pull/448","diff_url":"https://github.com/rendrjs/rendr/pull/448.diff","patch_url":"https://github.com/rendrjs/rendr/pull/448.patch","issue_url":"https://api.github.com/repos/rendrjs/rendr/issues/448","number":448,"state":"open","locked":false,"title":"Load controller from action for AMD version","user":{"login":"purusho","id":112441,"avatar_url":"https://avatars.githubusercontent.com/u/112441?v=3","gravatar_id":"","url":"https://api.github.com/users/purusho","html_url":"https://github.com/purusho","followers_url":"https://api.github.com/users/purusho/followers","following_url":"https://api.github.com/users/purusho/following{/other_user}","gists_url":"https://api.github.com/users/purusho/gists{/gist_id}","starred_url":"https://api.github.com/users/purusho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/purusho/subscriptions","organizations_url":"https://api.github.com/users/purusho/orgs","repos_url":"https://api.github.com/users/purusho/repos","events_url":"https://api.github.com/users/purusho/events{/privacy}","received_events_url":"https://api.github.com/users/purusho/received_events","type":"User","site_admin":false},"body":"This PR will fix the loading of controllers for the AMD version.\r\nSample App's PR : https://github.com/rendrjs/rendr-examples/pull/15","created_at":"2015-03-05T01:18:53Z","updated_at":"2015-03-05T23:42:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e9ad4390e1cfb9e6a036b3bc404721ab7bcb7ada","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/rendrjs/rendr/pulls/448/commits","review_comments_url":"https://api.github.com/repos/rendrjs/rendr/pulls/448/comments","review_comment_url":"https://api.github.com/repos/rendrjs/rendr/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rendrjs/rendr/issues/448/comments","statuses_url":"https://api.github.com/repos/rendrjs/rendr/statuses/8754d98f3340c5cff93117488c394d51510df7dc","head":{"label":"purusho:master","ref":"master","sha":"8754d98f3340c5cff93117488c394d51510df7dc","user":{"login":"purusho","id":112441,"avatar_url":"https://avatars.githubusercontent.com/u/112441?v=3","gravatar_id":"","url":"https://api.github.com/users/purusho","html_url":"https://github.com/purusho","followers_url":"https://api.github.com/users/purusho/followers","following_url":"https://api.github.com/users/purusho/following{/other_user}","gists_url":"https://api.github.com/users/purusho/gists{/gist_id}","starred_url":"https://api.github.com/users/purusho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/purusho/subscriptions","organizations_url":"https://api.github.com/users/purusho/orgs","repos_url":"https://api.github.com/users/purusho/repos","events_url":"https://api.github.com/users/purusho/events{/privacy}","received_events_url":"https://api.github.com/users/purusho/received_events","type":"User","site_admin":false},"repo":{"id":31685719,"name":"rendr","full_name":"purusho/rendr","owner":{"login":"purusho","id":112441,"avatar_url":"https://avatars.githubusercontent.com/u/112441?v=3","gravatar_id":"","url":"https://api.github.com/users/purusho","html_url":"https://github.com/purusho","followers_url":"https://api.github.com/users/purusho/followers","following_url":"https://api.github.com/users/purusho/following{/other_user}","gists_url":"https://api.github.com/users/purusho/gists{/gist_id}","starred_url":"https://api.github.com/users/purusho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/purusho/subscriptions","organizations_url":"https://api.github.com/users/purusho/orgs","repos_url":"https://api.github.com/users/purusho/repos","events_url":"https://api.github.com/users/purusho/events{/privacy}","received_events_url":"https://api.github.com/users/purusho/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/purusho/rendr","description":"Render your Backbone.js apps on the client and the server, using Node.js.","fork":true,"url":"https://api.github.com/repos/purusho/rendr","forks_url":"https://api.github.com/repos/purusho/rendr/forks","keys_url":"https://api.github.com/repos/purusho/rendr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/purusho/rendr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/purusho/rendr/teams","hooks_url":"https://api.github.com/repos/purusho/rendr/hooks","issue_events_url":"https://api.github.com/repos/purusho/rendr/issues/events{/number}","events_url":"https://api.github.com/repos/purusho/rendr/events","assignees_url":"https://api.github.com/repos/purusho/rendr/assignees{/user}","branches_url":"https://api.github.com/repos/purusho/rendr/branches{/branch}","tags_url":"https://api.github.com/repos/purusho/rendr/tags","blobs_url":"https://api.github.com/repos/purusho/rendr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/purusho/rendr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/purusho/rendr/git/refs{/sha}","trees_url":"https://api.github.com/repos/purusho/rendr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/purusho/rendr/statuses/{sha}","languages_url":"https://api.github.com/repos/purusho/rendr/languages","stargazers_url":"https://api.github.com/repos/purusho/rendr/stargazers","contributors_url":"https://api.github.com/repos/purusho/rendr/contributors","subscribers_url":"https://api.github.com/repos/purusho/rendr/subscribers","subscription_url":"https://api.github.com/repos/purusho/rendr/subscription","commits_url":"https://api.github.com/repos/purusho/rendr/commits{/sha}","git_commits_url":"https://api.github.com/repos/purusho/rendr/git/commits{/sha}","comments_url":"https://api.github.com/repos/purusho/rendr/comments{/number}","issue_comment_url":"https://api.github.com/repos/purusho/rendr/issues/comments{/number}","contents_url":"https://api.github.com/repos/purusho/rendr/contents/{+path}","compare_url":"https://api.github.com/repos/purusho/rendr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/purusho/rendr/merges","archive_url":"https://api.github.com/repos/purusho/rendr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/purusho/rendr/downloads","issues_url":"https://api.github.com/repos/purusho/rendr/issues{/number}","pulls_url":"https://api.github.com/repos/purusho/rendr/pulls{/number}","milestones_url":"https://api.github.com/repos/purusho/rendr/milestones{/number}","notifications_url":"https://api.github.com/repos/purusho/rendr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/purusho/rendr/labels{/name}","releases_url":"https://api.github.com/repos/purusho/rendr/releases{/id}","created_at":"2015-03-04T23:33:14Z","updated_at":"2015-03-04T23:48:42Z","pushed_at":"2015-03-04T23:48:42Z","git_url":"git://github.com/purusho/rendr.git","ssh_url":"git@github.com:purusho/rendr.git","clone_url":"https://github.com/purusho/rendr.git","svn_url":"https://github.com/purusho/rendr","homepage":"","size":5485,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"rendrjs:master","ref":"master","sha":"6829ddb7b6dee08df204ea85c15bc5decd608a72","user":{"login":"rendrjs","id":6723827,"avatar_url":"https://avatars.githubusercontent.com/u/6723827?v=3","gravatar_id":"","url":"https://api.github.com/users/rendrjs","html_url":"https://github.com/rendrjs","followers_url":"https://api.github.com/users/rendrjs/followers","following_url":"https://api.github.com/users/rendrjs/following{/other_user}","gists_url":"https://api.github.com/users/rendrjs/gists{/gist_id}","starred_url":"https://api.github.com/users/rendrjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rendrjs/subscriptions","organizations_url":"https://api.github.com/users/rendrjs/orgs","repos_url":"https://api.github.com/users/rendrjs/repos","events_url":"https://api.github.com/users/rendrjs/events{/privacy}","received_events_url":"https://api.github.com/users/rendrjs/received_events","type":"Organization","site_admin":false},"repo":{"id":6479425,"name":"rendr","full_name":"rendrjs/rendr","owner":{"login":"rendrjs","id":6723827,"avatar_url":"https://avatars.githubusercontent.com/u/6723827?v=3","gravatar_id":"","url":"https://api.github.com/users/rendrjs","html_url":"https://github.com/rendrjs","followers_url":"https://api.github.com/users/rendrjs/followers","following_url":"https://api.github.com/users/rendrjs/following{/other_user}","gists_url":"https://api.github.com/users/rendrjs/gists{/gist_id}","starred_url":"https://api.github.com/users/rendrjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rendrjs/subscriptions","organizations_url":"https://api.github.com/users/rendrjs/orgs","repos_url":"https://api.github.com/users/rendrjs/repos","events_url":"https://api.github.com/users/rendrjs/events{/privacy}","received_events_url":"https://api.github.com/users/rendrjs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rendrjs/rendr","description":"Render your Backbone.js apps on the client and the server, using Node.js.","fork":false,"url":"https://api.github.com/repos/rendrjs/rendr","forks_url":"https://api.github.com/repos/rendrjs/rendr/forks","keys_url":"https://api.github.com/repos/rendrjs/rendr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rendrjs/rendr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rendrjs/rendr/teams","hooks_url":"https://api.github.com/repos/rendrjs/rendr/hooks","issue_events_url":"https://api.github.com/repos/rendrjs/rendr/issues/events{/number}","events_url":"https://api.github.com/repos/rendrjs/rendr/events","assignees_url":"https://api.github.com/repos/rendrjs/rendr/assignees{/user}","branches_url":"https://api.github.com/repos/rendrjs/rendr/branches{/branch}","tags_url":"https://api.github.com/repos/rendrjs/rendr/tags","blobs_url":"https://api.github.com/repos/rendrjs/rendr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rendrjs/rendr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rendrjs/rendr/git/refs{/sha}","trees_url":"https://api.github.com/repos/rendrjs/rendr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rendrjs/rendr/statuses/{sha}","languages_url":"https://api.github.com/repos/rendrjs/rendr/languages","stargazers_url":"https://api.github.com/repos/rendrjs/rendr/stargazers","contributors_url":"https://api.github.com/repos/rendrjs/rendr/contributors","subscribers_url":"https://api.github.com/repos/rendrjs/rendr/subscribers","subscription_url":"https://api.github.com/repos/rendrjs/rendr/subscription","commits_url":"https://api.github.com/repos/rendrjs/rendr/commits{/sha}","git_commits_url":"https://api.github.com/repos/rendrjs/rendr/git/commits{/sha}","comments_url":"https://api.github.com/repos/rendrjs/rendr/comments{/number}","issue_comment_url":"https://api.github.com/repos/rendrjs/rendr/issues/comments{/number}","contents_url":"https://api.github.com/repos/rendrjs/rendr/contents/{+path}","compare_url":"https://api.github.com/repos/rendrjs/rendr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rendrjs/rendr/merges","archive_url":"https://api.github.com/repos/rendrjs/rendr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rendrjs/rendr/downloads","issues_url":"https://api.github.com/repos/rendrjs/rendr/issues{/number}","pulls_url":"https://api.github.com/repos/rendrjs/rendr/pulls{/number}","milestones_url":"https://api.github.com/repos/rendrjs/rendr/milestones{/number}","notifications_url":"https://api.github.com/repos/rendrjs/rendr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rendrjs/rendr/labels{/name}","releases_url":"https://api.github.com/repos/rendrjs/rendr/releases{/id}","created_at":"2012-10-31T19:24:35Z","updated_at":"2015-03-05T22:28:12Z","pushed_at":"2015-03-03T17:42:52Z","git_url":"git://github.com/rendrjs/rendr.git","ssh_url":"git@github.com:rendrjs/rendr.git","clone_url":"https://github.com/rendrjs/rendr.git","svn_url":"https://github.com/rendrjs/rendr","homepage":"","size":5485,"stargazers_count":3609,"watchers_count":3609,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":298,"mirror_url":null,"open_issues_count":71,"forks":298,"open_issues":71,"watchers":3609,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/448"},"html":{"href":"https://github.com/rendrjs/rendr/pull/448"},"issue":{"href":"https://api.github.com/repos/rendrjs/rendr/issues/448"},"comments":{"href":"https://api.github.com/repos/rendrjs/rendr/issues/448/comments"},"review_comments":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/448/comments"},"review_comment":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rendrjs/rendr/pulls/448/commits"},"statuses":{"href":"https://api.github.com/repos/rendrjs/rendr/statuses/8754d98f3340c5cff93117488c394d51510df7dc"}}}}