{"action":"created","comment":{"url":"https://api.github.com/repos/ripple/gatewayd/pulls/comments/24918654","id":24918654,"diff_hunk":"@@ -1,40 +1,21 @@\n var gateway = require(__dirname + '/../');\n var express = require('express');\n var bodyParser = require('body-parser');\n-var passport = require('passport');\n var publicCtrl = require(__dirname + '/http/controllers/public');\n var apiRouter = require(__dirname+'/http/routers/api_router.js');\n-var userRouter = require(__dirname+'/http/routers/user_router.js');\n-var adminRouter = require(__dirname+'/http/routers/admin_router.js');\n var resourcesRouter = require(__dirname+'/http/routers/resources_router.js');\n-var passportAuth = require(__dirname + '/http/passport_auth');\n const cors = require('cors')();\n \n process.env.DATABASE_URL = gateway.config.get('DATABASE_URL');\n \n-passport.use(passportAuth.adminBasic);\n-passport.use(passportAuth.userBasic);\n-\n var app = express();\n app.use(cors);\n app.use('/', express.static(gateway.config.get('WEBAPP_PATH')));\n app.use(bodyParser.json());\n app.use(bodyParser.urlencoded({ extended: true }));\n-app.use(passport.initialize());\n-\n-if (gateway.config.get('BASIC_AUTH')) {\n-  app.use('/v1', passport.authenticate('adminBasic', { session: false }), adminRouter);\n-  app.use('/v1', passport.authenticate('adminBasic', { session: false }), resourcesRouter);\n-  app.use('/v1', passport.authenticate('adminBasic', { session: false }), apiRouter);\n-} else {\n-  app.use('/v1', resourcesRouter);\n-  app.use('/v1', apiRouter);\n-}\n \n-if (gateway.config.get('USER_AUTH')) {\n-  app.post('/v1/register', publicCtrl.registerUser);\n-  app.use('/v1', passport.authenticate('userBasic', { session: false }), userRouter);\n-}\n+app.use('/v1', resourcesRouter);\n+app.use('/v1', apiRouter);\n \n app.get('/ripple.txt', publicCtrl.rippleTxt);","path":"lib/app.js","position":41,"original_position":41,"commit_id":"b18c008c6b9e50b0d60ae6018dc73e72ee667c4c","original_commit_id":"b18c008c6b9e50b0d60ae6018dc73e72ee667c4c","user":{"login":"cdmcnamara","id":1103780,"avatar_url":"https://avatars.githubusercontent.com/u/1103780?v=3","gravatar_id":"","url":"https://api.github.com/users/cdmcnamara","html_url":"https://github.com/cdmcnamara","followers_url":"https://api.github.com/users/cdmcnamara/followers","following_url":"https://api.github.com/users/cdmcnamara/following{/other_user}","gists_url":"https://api.github.com/users/cdmcnamara/gists{/gist_id}","starred_url":"https://api.github.com/users/cdmcnamara/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cdmcnamara/subscriptions","organizations_url":"https://api.github.com/users/cdmcnamara/orgs","repos_url":"https://api.github.com/users/cdmcnamara/repos","events_url":"https://api.github.com/users/cdmcnamara/events{/privacy}","received_events_url":"https://api.github.com/users/cdmcnamara/received_events","type":"User","site_admin":false},"body":"Let's remove this too.","created_at":"2015-02-18T17:05:52Z","updated_at":"2015-02-18T17:05:52Z","html_url":"https://github.com/ripple/gatewayd/pull/575#discussion_r24918654","pull_request_url":"https://api.github.com/repos/ripple/gatewayd/pulls/575","_links":{"self":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/comments/24918654"},"html":{"href":"https://github.com/ripple/gatewayd/pull/575#discussion_r24918654"},"pull_request":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/575"}}},"pull_request":{"url":"https://api.github.com/repos/ripple/gatewayd/pulls/575","id":29493481,"html_url":"https://github.com/ripple/gatewayd/pull/575","diff_url":"https://github.com/ripple/gatewayd/pull/575.diff","patch_url":"https://github.com/ripple/gatewayd/pull/575.patch","issue_url":"https://api.github.com/repos/ripple/gatewayd/issues/575","number":575,"state":"closed","locked":false,"title":"Remove unused endpoints","user":{"login":"nerdylocks","id":4754461,"avatar_url":"https://avatars.githubusercontent.com/u/4754461?v=3","gravatar_id":"","url":"https://api.github.com/users/nerdylocks","html_url":"https://github.com/nerdylocks","followers_url":"https://api.github.com/users/nerdylocks/followers","following_url":"https://api.github.com/users/nerdylocks/following{/other_user}","gists_url":"https://api.github.com/users/nerdylocks/gists{/gist_id}","starred_url":"https://api.github.com/users/nerdylocks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nerdylocks/subscriptions","organizations_url":"https://api.github.com/users/nerdylocks/orgs","repos_url":"https://api.github.com/users/nerdylocks/repos","events_url":"https://api.github.com/users/nerdylocks/events{/privacy}","received_events_url":"https://api.github.com/users/nerdylocks/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-02-18T01:06:53Z","updated_at":"2015-02-18T17:05:52Z","closed_at":"2015-02-18T01:40:51Z","merged_at":null,"merge_commit_sha":"7cb79384f23e8431a75cd40b42fe19413fdd6043","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ripple/gatewayd/pulls/575/commits","review_comments_url":"https://api.github.com/repos/ripple/gatewayd/pulls/575/comments","review_comment_url":"https://api.github.com/repos/ripple/gatewayd/pulls/comments/{number}","comments_url":"https://api.github.com/repos/ripple/gatewayd/issues/575/comments","statuses_url":"https://api.github.com/repos/ripple/gatewayd/statuses/b18c008c6b9e50b0d60ae6018dc73e72ee667c4c","head":{"label":"ripple:refactor/remove-unsed-endpoints","ref":"refactor/remove-unsed-endpoints","sha":"b18c008c6b9e50b0d60ae6018dc73e72ee667c4c","user":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"repo":{"id":15145198,"name":"gatewayd","full_name":"ripple/gatewayd","owner":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ripple/gatewayd","description":"Connecting Ledgers","fork":false,"url":"https://api.github.com/repos/ripple/gatewayd","forks_url":"https://api.github.com/repos/ripple/gatewayd/forks","keys_url":"https://api.github.com/repos/ripple/gatewayd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ripple/gatewayd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ripple/gatewayd/teams","hooks_url":"https://api.github.com/repos/ripple/gatewayd/hooks","issue_events_url":"https://api.github.com/repos/ripple/gatewayd/issues/events{/number}","events_url":"https://api.github.com/repos/ripple/gatewayd/events","assignees_url":"https://api.github.com/repos/ripple/gatewayd/assignees{/user}","branches_url":"https://api.github.com/repos/ripple/gatewayd/branches{/branch}","tags_url":"https://api.github.com/repos/ripple/gatewayd/tags","blobs_url":"https://api.github.com/repos/ripple/gatewayd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ripple/gatewayd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ripple/gatewayd/git/refs{/sha}","trees_url":"https://api.github.com/repos/ripple/gatewayd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ripple/gatewayd/statuses/{sha}","languages_url":"https://api.github.com/repos/ripple/gatewayd/languages","stargazers_url":"https://api.github.com/repos/ripple/gatewayd/stargazers","contributors_url":"https://api.github.com/repos/ripple/gatewayd/contributors","subscribers_url":"https://api.github.com/repos/ripple/gatewayd/subscribers","subscription_url":"https://api.github.com/repos/ripple/gatewayd/subscription","commits_url":"https://api.github.com/repos/ripple/gatewayd/commits{/sha}","git_commits_url":"https://api.github.com/repos/ripple/gatewayd/git/commits{/sha}","comments_url":"https://api.github.com/repos/ripple/gatewayd/comments{/number}","issue_comment_url":"https://api.github.com/repos/ripple/gatewayd/issues/comments/{number}","contents_url":"https://api.github.com/repos/ripple/gatewayd/contents/{+path}","compare_url":"https://api.github.com/repos/ripple/gatewayd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ripple/gatewayd/merges","archive_url":"https://api.github.com/repos/ripple/gatewayd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ripple/gatewayd/downloads","issues_url":"https://api.github.com/repos/ripple/gatewayd/issues{/number}","pulls_url":"https://api.github.com/repos/ripple/gatewayd/pulls{/number}","milestones_url":"https://api.github.com/repos/ripple/gatewayd/milestones{/number}","notifications_url":"https://api.github.com/repos/ripple/gatewayd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ripple/gatewayd/labels{/name}","releases_url":"https://api.github.com/repos/ripple/gatewayd/releases{/id}","created_at":"2013-12-12T19:23:16Z","updated_at":"2015-02-17T20:51:42Z","pushed_at":"2015-02-18T01:39:34Z","git_url":"git://github.com/ripple/gatewayd.git","ssh_url":"git@github.com:ripple/gatewayd.git","clone_url":"https://github.com/ripple/gatewayd.git","svn_url":"https://github.com/ripple/gatewayd","homepage":"https://gatewayd.org","size":38354,"stargazers_count":94,"watchers_count":94,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":92,"mirror_url":null,"open_issues_count":28,"forks":92,"open_issues":28,"watchers":94,"default_branch":"master"}},"base":{"label":"ripple:master","ref":"master","sha":"14b4491bdd7920eddf6e60e3ad1b961896c4c523","user":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"repo":{"id":15145198,"name":"gatewayd","full_name":"ripple/gatewayd","owner":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ripple/gatewayd","description":"Connecting Ledgers","fork":false,"url":"https://api.github.com/repos/ripple/gatewayd","forks_url":"https://api.github.com/repos/ripple/gatewayd/forks","keys_url":"https://api.github.com/repos/ripple/gatewayd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ripple/gatewayd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ripple/gatewayd/teams","hooks_url":"https://api.github.com/repos/ripple/gatewayd/hooks","issue_events_url":"https://api.github.com/repos/ripple/gatewayd/issues/events{/number}","events_url":"https://api.github.com/repos/ripple/gatewayd/events","assignees_url":"https://api.github.com/repos/ripple/gatewayd/assignees{/user}","branches_url":"https://api.github.com/repos/ripple/gatewayd/branches{/branch}","tags_url":"https://api.github.com/repos/ripple/gatewayd/tags","blobs_url":"https://api.github.com/repos/ripple/gatewayd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ripple/gatewayd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ripple/gatewayd/git/refs{/sha}","trees_url":"https://api.github.com/repos/ripple/gatewayd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ripple/gatewayd/statuses/{sha}","languages_url":"https://api.github.com/repos/ripple/gatewayd/languages","stargazers_url":"https://api.github.com/repos/ripple/gatewayd/stargazers","contributors_url":"https://api.github.com/repos/ripple/gatewayd/contributors","subscribers_url":"https://api.github.com/repos/ripple/gatewayd/subscribers","subscription_url":"https://api.github.com/repos/ripple/gatewayd/subscription","commits_url":"https://api.github.com/repos/ripple/gatewayd/commits{/sha}","git_commits_url":"https://api.github.com/repos/ripple/gatewayd/git/commits{/sha}","comments_url":"https://api.github.com/repos/ripple/gatewayd/comments{/number}","issue_comment_url":"https://api.github.com/repos/ripple/gatewayd/issues/comments/{number}","contents_url":"https://api.github.com/repos/ripple/gatewayd/contents/{+path}","compare_url":"https://api.github.com/repos/ripple/gatewayd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ripple/gatewayd/merges","archive_url":"https://api.github.com/repos/ripple/gatewayd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ripple/gatewayd/downloads","issues_url":"https://api.github.com/repos/ripple/gatewayd/issues{/number}","pulls_url":"https://api.github.com/repos/ripple/gatewayd/pulls{/number}","milestones_url":"https://api.github.com/repos/ripple/gatewayd/milestones{/number}","notifications_url":"https://api.github.com/repos/ripple/gatewayd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ripple/gatewayd/labels{/name}","releases_url":"https://api.github.com/repos/ripple/gatewayd/releases{/id}","created_at":"2013-12-12T19:23:16Z","updated_at":"2015-02-17T20:51:42Z","pushed_at":"2015-02-18T01:39:34Z","git_url":"git://github.com/ripple/gatewayd.git","ssh_url":"git@github.com:ripple/gatewayd.git","clone_url":"https://github.com/ripple/gatewayd.git","svn_url":"https://github.com/ripple/gatewayd","homepage":"https://gatewayd.org","size":38354,"stargazers_count":94,"watchers_count":94,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":92,"mirror_url":null,"open_issues_count":28,"forks":92,"open_issues":28,"watchers":94,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/575"},"html":{"href":"https://github.com/ripple/gatewayd/pull/575"},"issue":{"href":"https://api.github.com/repos/ripple/gatewayd/issues/575"},"comments":{"href":"https://api.github.com/repos/ripple/gatewayd/issues/575/comments"},"review_comments":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/575/comments"},"review_comment":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/ripple/gatewayd/pulls/575/commits"},"statuses":{"href":"https://api.github.com/repos/ripple/gatewayd/statuses/b18c008c6b9e50b0d60ae6018dc73e72ee667c4c"}}}}