{"action":"created","comment":{"url":"https://api.github.com/repos/Ad1n/simpler/pulls/comments/226693787","pull_request_review_id":166582596,"id":226693787,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNjY5Mzc4Nw==","diff_hunk":"@@ -0,0 +1,48 @@\n+require 'logger'\n+\n+class AppLogger\n+\n+  def initialize(app, **options)\n+    @logger = Logger.new(options[:logdev] || STDOUT)\n+    @app = app\n+  end\n+\n+  def call(env)\n+    status, headers, body = @app.call(env)\n+    generate_logger_string(env, status, headers)\n+    [status, headers, body]\n+  end\n+\n+  private\n+\n+  def generate_logger_string(env, status, headers)\n+    check_template(env)\n+    check_controller_action(env)\n+\n+    env[\"simpler.params\"] = \"\" if env[\"simpler.params\"].nil?","path":"lib/middleware/logger.rb","position":22,"original_position":22,"commit_id":"66a3d372330ffe847b43e89b248b53c2b72acef3","original_commit_id":"66a3d372330ffe847b43e89b248b53c2b72acef3","user":{"login":"iBublik","id":11278497,"node_id":"MDQ6VXNlcjExMjc4NDk3","avatar_url":"https://avatars1.githubusercontent.com/u/11278497?v=4","gravatar_id":"","url":"https://api.github.com/users/iBublik","html_url":"https://github.com/iBublik","followers_url":"https://api.github.com/users/iBublik/followers","following_url":"https://api.github.com/users/iBublik/following{/other_user}","gists_url":"https://api.github.com/users/iBublik/gists{/gist_id}","starred_url":"https://api.github.com/users/iBublik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iBublik/subscriptions","organizations_url":"https://api.github.com/users/iBublik/orgs","repos_url":"https://api.github.com/users/iBublik/repos","events_url":"https://api.github.com/users/iBublik/events{/privacy}","received_events_url":"https://api.github.com/users/iBublik/received_events","type":"User","site_admin":false},"body":"Почему у тебя логгер меняет env? Он не должен таким заниматься. его задача - просто логировать информацию, он не должен мутировать ничего","created_at":"2018-10-19T15:45:48Z","updated_at":"2018-10-19T15:55:42Z","html_url":"https://github.com/Ad1n/simpler/pull/1#discussion_r226693787","pull_request_url":"https://api.github.com/repos/Ad1n/simpler/pulls/1","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/comments/226693787"},"html":{"href":"https://github.com/Ad1n/simpler/pull/1#discussion_r226693787"},"pull_request":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/Ad1n/simpler/pulls/1","id":224227313,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0MjI3MzEz","html_url":"https://github.com/Ad1n/simpler/pull/1","diff_url":"https://github.com/Ad1n/simpler/pull/1.diff","patch_url":"https://github.com/Ad1n/simpler/pull/1.patch","issue_url":"https://api.github.com/repos/Ad1n/simpler/issues/1","number":1,"state":"open","locked":false,"title":"Lesson 20. Framework","user":{"login":"Ad1n","id":35301357,"node_id":"MDQ6VXNlcjM1MzAxMzU3","avatar_url":"https://avatars1.githubusercontent.com/u/35301357?v=4","gravatar_id":"","url":"https://api.github.com/users/Ad1n","html_url":"https://github.com/Ad1n","followers_url":"https://api.github.com/users/Ad1n/followers","following_url":"https://api.github.com/users/Ad1n/following{/other_user}","gists_url":"https://api.github.com/users/Ad1n/gists{/gist_id}","starred_url":"https://api.github.com/users/Ad1n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ad1n/subscriptions","organizations_url":"https://api.github.com/users/Ad1n/orgs","repos_url":"https://api.github.com/users/Ad1n/repos","events_url":"https://api.github.com/users/Ad1n/events{/privacy}","received_events_url":"https://api.github.com/users/Ad1n/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-10-19T09:40:14Z","updated_at":"2018-10-19T15:55:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"778bed28d4bda814e124c161c13dda49d3deea8b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/Ad1n/simpler/pulls/1/commits","review_comments_url":"https://api.github.com/repos/Ad1n/simpler/pulls/1/comments","review_comment_url":"https://api.github.com/repos/Ad1n/simpler/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Ad1n/simpler/issues/1/comments","statuses_url":"https://api.github.com/repos/Ad1n/simpler/statuses/66a3d372330ffe847b43e89b248b53c2b72acef3","head":{"label":"Ad1n:Lesson20","ref":"Lesson20","sha":"66a3d372330ffe847b43e89b248b53c2b72acef3","user":{"login":"Ad1n","id":35301357,"node_id":"MDQ6VXNlcjM1MzAxMzU3","avatar_url":"https://avatars1.githubusercontent.com/u/35301357?v=4","gravatar_id":"","url":"https://api.github.com/users/Ad1n","html_url":"https://github.com/Ad1n","followers_url":"https://api.github.com/users/Ad1n/followers","following_url":"https://api.github.com/users/Ad1n/following{/other_user}","gists_url":"https://api.github.com/users/Ad1n/gists{/gist_id}","starred_url":"https://api.github.com/users/Ad1n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ad1n/subscriptions","organizations_url":"https://api.github.com/users/Ad1n/orgs","repos_url":"https://api.github.com/users/Ad1n/repos","events_url":"https://api.github.com/users/Ad1n/events{/privacy}","received_events_url":"https://api.github.com/users/Ad1n/received_events","type":"User","site_admin":false},"repo":{"id":153072455,"node_id":"MDEwOlJlcG9zaXRvcnkxNTMwNzI0NTU=","name":"simpler","full_name":"Ad1n/simpler","private":false,"owner":{"login":"Ad1n","id":35301357,"node_id":"MDQ6VXNlcjM1MzAxMzU3","avatar_url":"https://avatars1.githubusercontent.com/u/35301357?v=4","gravatar_id":"","url":"https://api.github.com/users/Ad1n","html_url":"https://github.com/Ad1n","followers_url":"https://api.github.com/users/Ad1n/followers","following_url":"https://api.github.com/users/Ad1n/following{/other_user}","gists_url":"https://api.github.com/users/Ad1n/gists{/gist_id}","starred_url":"https://api.github.com/users/Ad1n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ad1n/subscriptions","organizations_url":"https://api.github.com/users/Ad1n/orgs","repos_url":"https://api.github.com/users/Ad1n/repos","events_url":"https://api.github.com/users/Ad1n/events{/privacy}","received_events_url":"https://api.github.com/users/Ad1n/received_events","type":"User","site_admin":false},"html_url":"https://github.com/Ad1n/simpler","description":null,"fork":true,"url":"https://api.github.com/repos/Ad1n/simpler","forks_url":"https://api.github.com/repos/Ad1n/simpler/forks","keys_url":"https://api.github.com/repos/Ad1n/simpler/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Ad1n/simpler/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Ad1n/simpler/teams","hooks_url":"https://api.github.com/repos/Ad1n/simpler/hooks","issue_events_url":"https://api.github.com/repos/Ad1n/simpler/issues/events{/number}","events_url":"https://api.github.com/repos/Ad1n/simpler/events","assignees_url":"https://api.github.com/repos/Ad1n/simpler/assignees{/user}","branches_url":"https://api.github.com/repos/Ad1n/simpler/branches{/branch}","tags_url":"https://api.github.com/repos/Ad1n/simpler/tags","blobs_url":"https://api.github.com/repos/Ad1n/simpler/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Ad1n/simpler/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Ad1n/simpler/git/refs{/sha}","trees_url":"https://api.github.com/repos/Ad1n/simpler/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Ad1n/simpler/statuses/{sha}","languages_url":"https://api.github.com/repos/Ad1n/simpler/languages","stargazers_url":"https://api.github.com/repos/Ad1n/simpler/stargazers","contributors_url":"https://api.github.com/repos/Ad1n/simpler/contributors","subscribers_url":"https://api.github.com/repos/Ad1n/simpler/subscribers","subscription_url":"https://api.github.com/repos/Ad1n/simpler/subscription","commits_url":"https://api.github.com/repos/Ad1n/simpler/commits{/sha}","git_commits_url":"https://api.github.com/repos/Ad1n/simpler/git/commits{/sha}","comments_url":"https://api.github.com/repos/Ad1n/simpler/comments{/number}","issue_comment_url":"https://api.github.com/repos/Ad1n/simpler/issues/comments{/number}","contents_url":"https://api.github.com/repos/Ad1n/simpler/contents/{+path}","compare_url":"https://api.github.com/repos/Ad1n/simpler/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Ad1n/simpler/merges","archive_url":"https://api.github.com/repos/Ad1n/simpler/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Ad1n/simpler/downloads","issues_url":"https://api.github.com/repos/Ad1n/simpler/issues{/number}","pulls_url":"https://api.github.com/repos/Ad1n/simpler/pulls{/number}","milestones_url":"https://api.github.com/repos/Ad1n/simpler/milestones{/number}","notifications_url":"https://api.github.com/repos/Ad1n/simpler/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Ad1n/simpler/labels{/name}","releases_url":"https://api.github.com/repos/Ad1n/simpler/releases{/id}","deployments_url":"https://api.github.com/repos/Ad1n/simpler/deployments","created_at":"2018-10-15T07:43:01Z","updated_at":"2018-10-15T07:43:03Z","pushed_at":"2018-10-19T09:40:15Z","git_url":"git://github.com/Ad1n/simpler.git","ssh_url":"git@github.com:Ad1n/simpler.git","clone_url":"https://github.com/Ad1n/simpler.git","svn_url":"https://github.com/Ad1n/simpler","homepage":null,"size":12,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"Ad1n:master","ref":"master","sha":"c3d0a7863d0ef1e6a21bae73fe055ff130a045fa","user":{"login":"Ad1n","id":35301357,"node_id":"MDQ6VXNlcjM1MzAxMzU3","avatar_url":"https://avatars1.githubusercontent.com/u/35301357?v=4","gravatar_id":"","url":"https://api.github.com/users/Ad1n","html_url":"https://github.com/Ad1n","followers_url":"https://api.github.com/users/Ad1n/followers","following_url":"https://api.github.com/users/Ad1n/following{/other_user}","gists_url":"https://api.github.com/users/Ad1n/gists{/gist_id}","starred_url":"https://api.github.com/users/Ad1n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ad1n/subscriptions","organizations_url":"https://api.github.com/users/Ad1n/orgs","repos_url":"https://api.github.com/users/Ad1n/repos","events_url":"https://api.github.com/users/Ad1n/events{/privacy}","received_events_url":"https://api.github.com/users/Ad1n/received_events","type":"User","site_admin":false},"repo":{"id":153072455,"node_id":"MDEwOlJlcG9zaXRvcnkxNTMwNzI0NTU=","name":"simpler","full_name":"Ad1n/simpler","private":false,"owner":{"login":"Ad1n","id":35301357,"node_id":"MDQ6VXNlcjM1MzAxMzU3","avatar_url":"https://avatars1.githubusercontent.com/u/35301357?v=4","gravatar_id":"","url":"https://api.github.com/users/Ad1n","html_url":"https://github.com/Ad1n","followers_url":"https://api.github.com/users/Ad1n/followers","following_url":"https://api.github.com/users/Ad1n/following{/other_user}","gists_url":"https://api.github.com/users/Ad1n/gists{/gist_id}","starred_url":"https://api.github.com/users/Ad1n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ad1n/subscriptions","organizations_url":"https://api.github.com/users/Ad1n/orgs","repos_url":"https://api.github.com/users/Ad1n/repos","events_url":"https://api.github.com/users/Ad1n/events{/privacy}","received_events_url":"https://api.github.com/users/Ad1n/received_events","type":"User","site_admin":false},"html_url":"https://github.com/Ad1n/simpler","description":null,"fork":true,"url":"https://api.github.com/repos/Ad1n/simpler","forks_url":"https://api.github.com/repos/Ad1n/simpler/forks","keys_url":"https://api.github.com/repos/Ad1n/simpler/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Ad1n/simpler/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Ad1n/simpler/teams","hooks_url":"https://api.github.com/repos/Ad1n/simpler/hooks","issue_events_url":"https://api.github.com/repos/Ad1n/simpler/issues/events{/number}","events_url":"https://api.github.com/repos/Ad1n/simpler/events","assignees_url":"https://api.github.com/repos/Ad1n/simpler/assignees{/user}","branches_url":"https://api.github.com/repos/Ad1n/simpler/branches{/branch}","tags_url":"https://api.github.com/repos/Ad1n/simpler/tags","blobs_url":"https://api.github.com/repos/Ad1n/simpler/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Ad1n/simpler/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Ad1n/simpler/git/refs{/sha}","trees_url":"https://api.github.com/repos/Ad1n/simpler/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Ad1n/simpler/statuses/{sha}","languages_url":"https://api.github.com/repos/Ad1n/simpler/languages","stargazers_url":"https://api.github.com/repos/Ad1n/simpler/stargazers","contributors_url":"https://api.github.com/repos/Ad1n/simpler/contributors","subscribers_url":"https://api.github.com/repos/Ad1n/simpler/subscribers","subscription_url":"https://api.github.com/repos/Ad1n/simpler/subscription","commits_url":"https://api.github.com/repos/Ad1n/simpler/commits{/sha}","git_commits_url":"https://api.github.com/repos/Ad1n/simpler/git/commits{/sha}","comments_url":"https://api.github.com/repos/Ad1n/simpler/comments{/number}","issue_comment_url":"https://api.github.com/repos/Ad1n/simpler/issues/comments{/number}","contents_url":"https://api.github.com/repos/Ad1n/simpler/contents/{+path}","compare_url":"https://api.github.com/repos/Ad1n/simpler/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Ad1n/simpler/merges","archive_url":"https://api.github.com/repos/Ad1n/simpler/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Ad1n/simpler/downloads","issues_url":"https://api.github.com/repos/Ad1n/simpler/issues{/number}","pulls_url":"https://api.github.com/repos/Ad1n/simpler/pulls{/number}","milestones_url":"https://api.github.com/repos/Ad1n/simpler/milestones{/number}","notifications_url":"https://api.github.com/repos/Ad1n/simpler/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Ad1n/simpler/labels{/name}","releases_url":"https://api.github.com/repos/Ad1n/simpler/releases{/id}","deployments_url":"https://api.github.com/repos/Ad1n/simpler/deployments","created_at":"2018-10-15T07:43:01Z","updated_at":"2018-10-15T07:43:03Z","pushed_at":"2018-10-19T09:40:15Z","git_url":"git://github.com/Ad1n/simpler.git","ssh_url":"git@github.com:Ad1n/simpler.git","clone_url":"https://github.com/Ad1n/simpler.git","svn_url":"https://github.com/Ad1n/simpler","homepage":null,"size":12,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/1"},"html":{"href":"https://github.com/Ad1n/simpler/pull/1"},"issue":{"href":"https://api.github.com/repos/Ad1n/simpler/issues/1"},"comments":{"href":"https://api.github.com/repos/Ad1n/simpler/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Ad1n/simpler/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/Ad1n/simpler/statuses/66a3d372330ffe847b43e89b248b53c2b72acef3"}},"author_association":"OWNER"}}
{"actor":{"display_login":"iBublik"}}