{"action":"closed","number":220,"pull_request":{"url":"https://api.github.com/repos/top-think/framework/pulls/220","id":77903300,"html_url":"https://github.com/top-think/framework/pull/220","diff_url":"https://github.com/top-think/framework/pull/220.diff","patch_url":"https://github.com/top-think/framework/pull/220.patch","issue_url":"https://api.github.com/repos/top-think/framework/issues/220","number":220,"state":"closed","locked":false,"title":"精简代码getData方法代码","user":{"login":"WeakSun","id":5387717,"avatar_url":"https://avatars.githubusercontent.com/u/5387717?v=3","gravatar_id":"","url":"https://api.github.com/users/WeakSun","html_url":"https://github.com/WeakSun","followers_url":"https://api.github.com/users/WeakSun/followers","following_url":"https://api.github.com/users/WeakSun/following{/other_user}","gists_url":"https://api.github.com/users/WeakSun/gists{/gist_id}","starred_url":"https://api.github.com/users/WeakSun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WeakSun/subscriptions","organizations_url":"https://api.github.com/users/WeakSun/orgs","repos_url":"https://api.github.com/users/WeakSun/repos","events_url":"https://api.github.com/users/WeakSun/events{/privacy}","received_events_url":"https://api.github.com/users/WeakSun/received_events","type":"User","site_admin":false},"body":"1. getData方法的 if 改为三元，去掉array_key_exists步骤；\r\n2. getData方法去掉throw动作，由PHP报错级别控制（error_reporting函数）；\r\n3.getAttr方法去掉try以及$notFound变量；\r\n4.getAttr方法获取器和转换器直接使用data成员。\r\n\r\n本次修改主要是将值不存在这种错误统一由PHP报错级别控制。\r\n\r\n","created_at":"2016-07-19T00:59:28Z","updated_at":"2016-07-19T02:32:12Z","closed_at":"2016-07-19T02:32:12Z","merged_at":null,"merge_commit_sha":"e4d0ce2918abbfa4950bdd2cc4c8cdcb9a2fc607","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/top-think/framework/pulls/220/commits","review_comments_url":"https://api.github.com/repos/top-think/framework/pulls/220/comments","review_comment_url":"https://api.github.com/repos/top-think/framework/pulls/comments{/number}","comments_url":"https://api.github.com/repos/top-think/framework/issues/220/comments","statuses_url":"https://api.github.com/repos/top-think/framework/statuses/98cf1454b5c689651965472eb5400e2c25667549","head":{"label":"WeakSun:patch-2","ref":"patch-2","sha":"98cf1454b5c689651965472eb5400e2c25667549","user":{"login":"WeakSun","id":5387717,"avatar_url":"https://avatars.githubusercontent.com/u/5387717?v=3","gravatar_id":"","url":"https://api.github.com/users/WeakSun","html_url":"https://github.com/WeakSun","followers_url":"https://api.github.com/users/WeakSun/followers","following_url":"https://api.github.com/users/WeakSun/following{/other_user}","gists_url":"https://api.github.com/users/WeakSun/gists{/gist_id}","starred_url":"https://api.github.com/users/WeakSun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WeakSun/subscriptions","organizations_url":"https://api.github.com/users/WeakSun/orgs","repos_url":"https://api.github.com/users/WeakSun/repos","events_url":"https://api.github.com/users/WeakSun/events{/privacy}","received_events_url":"https://api.github.com/users/WeakSun/received_events","type":"User","site_admin":false},"repo":{"id":62443876,"name":"framework","full_name":"WeakSun/framework","owner":{"login":"WeakSun","id":5387717,"avatar_url":"https://avatars.githubusercontent.com/u/5387717?v=3","gravatar_id":"","url":"https://api.github.com/users/WeakSun","html_url":"https://github.com/WeakSun","followers_url":"https://api.github.com/users/WeakSun/followers","following_url":"https://api.github.com/users/WeakSun/following{/other_user}","gists_url":"https://api.github.com/users/WeakSun/gists{/gist_id}","starred_url":"https://api.github.com/users/WeakSun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WeakSun/subscriptions","organizations_url":"https://api.github.com/users/WeakSun/orgs","repos_url":"https://api.github.com/users/WeakSun/repos","events_url":"https://api.github.com/users/WeakSun/events{/privacy}","received_events_url":"https://api.github.com/users/WeakSun/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/WeakSun/framework","description":"ThinkPHP5 核心框架包","fork":true,"url":"https://api.github.com/repos/WeakSun/framework","forks_url":"https://api.github.com/repos/WeakSun/framework/forks","keys_url":"https://api.github.com/repos/WeakSun/framework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WeakSun/framework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WeakSun/framework/teams","hooks_url":"https://api.github.com/repos/WeakSun/framework/hooks","issue_events_url":"https://api.github.com/repos/WeakSun/framework/issues/events{/number}","events_url":"https://api.github.com/repos/WeakSun/framework/events","assignees_url":"https://api.github.com/repos/WeakSun/framework/assignees{/user}","branches_url":"https://api.github.com/repos/WeakSun/framework/branches{/branch}","tags_url":"https://api.github.com/repos/WeakSun/framework/tags","blobs_url":"https://api.github.com/repos/WeakSun/framework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WeakSun/framework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WeakSun/framework/git/refs{/sha}","trees_url":"https://api.github.com/repos/WeakSun/framework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WeakSun/framework/statuses/{sha}","languages_url":"https://api.github.com/repos/WeakSun/framework/languages","stargazers_url":"https://api.github.com/repos/WeakSun/framework/stargazers","contributors_url":"https://api.github.com/repos/WeakSun/framework/contributors","subscribers_url":"https://api.github.com/repos/WeakSun/framework/subscribers","subscription_url":"https://api.github.com/repos/WeakSun/framework/subscription","commits_url":"https://api.github.com/repos/WeakSun/framework/commits{/sha}","git_commits_url":"https://api.github.com/repos/WeakSun/framework/git/commits{/sha}","comments_url":"https://api.github.com/repos/WeakSun/framework/comments{/number}","issue_comment_url":"https://api.github.com/repos/WeakSun/framework/issues/comments{/number}","contents_url":"https://api.github.com/repos/WeakSun/framework/contents/{+path}","compare_url":"https://api.github.com/repos/WeakSun/framework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WeakSun/framework/merges","archive_url":"https://api.github.com/repos/WeakSun/framework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WeakSun/framework/downloads","issues_url":"https://api.github.com/repos/WeakSun/framework/issues{/number}","pulls_url":"https://api.github.com/repos/WeakSun/framework/pulls{/number}","milestones_url":"https://api.github.com/repos/WeakSun/framework/milestones{/number}","notifications_url":"https://api.github.com/repos/WeakSun/framework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WeakSun/framework/labels{/name}","releases_url":"https://api.github.com/repos/WeakSun/framework/releases{/id}","deployments_url":"https://api.github.com/repos/WeakSun/framework/deployments","created_at":"2016-07-02T09:33:41Z","updated_at":"2016-07-02T09:33:42Z","pushed_at":"2016-07-19T01:59:10Z","git_url":"git://github.com/WeakSun/framework.git","ssh_url":"git@github.com:WeakSun/framework.git","clone_url":"https://github.com/WeakSun/framework.git","svn_url":"https://github.com/WeakSun/framework","homepage":"","size":7325,"stargazers_count":0,"watchers_count":0,"language":"PHP","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":"top-think:master","ref":"master","sha":"746a76360618afb76b90f1bcfa34918afd57f1c7","user":{"login":"top-think","id":16305258,"avatar_url":"https://avatars.githubusercontent.com/u/16305258?v=3","gravatar_id":"","url":"https://api.github.com/users/top-think","html_url":"https://github.com/top-think","followers_url":"https://api.github.com/users/top-think/followers","following_url":"https://api.github.com/users/top-think/following{/other_user}","gists_url":"https://api.github.com/users/top-think/gists{/gist_id}","starred_url":"https://api.github.com/users/top-think/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/top-think/subscriptions","organizations_url":"https://api.github.com/users/top-think/orgs","repos_url":"https://api.github.com/users/top-think/repos","events_url":"https://api.github.com/users/top-think/events{/privacy}","received_events_url":"https://api.github.com/users/top-think/received_events","type":"Organization","site_admin":false},"repo":{"id":48530411,"name":"framework","full_name":"top-think/framework","owner":{"login":"top-think","id":16305258,"avatar_url":"https://avatars.githubusercontent.com/u/16305258?v=3","gravatar_id":"","url":"https://api.github.com/users/top-think","html_url":"https://github.com/top-think","followers_url":"https://api.github.com/users/top-think/followers","following_url":"https://api.github.com/users/top-think/following{/other_user}","gists_url":"https://api.github.com/users/top-think/gists{/gist_id}","starred_url":"https://api.github.com/users/top-think/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/top-think/subscriptions","organizations_url":"https://api.github.com/users/top-think/orgs","repos_url":"https://api.github.com/users/top-think/repos","events_url":"https://api.github.com/users/top-think/events{/privacy}","received_events_url":"https://api.github.com/users/top-think/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/top-think/framework","description":"ThinkPHP5 核心框架包","fork":false,"url":"https://api.github.com/repos/top-think/framework","forks_url":"https://api.github.com/repos/top-think/framework/forks","keys_url":"https://api.github.com/repos/top-think/framework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/top-think/framework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/top-think/framework/teams","hooks_url":"https://api.github.com/repos/top-think/framework/hooks","issue_events_url":"https://api.github.com/repos/top-think/framework/issues/events{/number}","events_url":"https://api.github.com/repos/top-think/framework/events","assignees_url":"https://api.github.com/repos/top-think/framework/assignees{/user}","branches_url":"https://api.github.com/repos/top-think/framework/branches{/branch}","tags_url":"https://api.github.com/repos/top-think/framework/tags","blobs_url":"https://api.github.com/repos/top-think/framework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/top-think/framework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/top-think/framework/git/refs{/sha}","trees_url":"https://api.github.com/repos/top-think/framework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/top-think/framework/statuses/{sha}","languages_url":"https://api.github.com/repos/top-think/framework/languages","stargazers_url":"https://api.github.com/repos/top-think/framework/stargazers","contributors_url":"https://api.github.com/repos/top-think/framework/contributors","subscribers_url":"https://api.github.com/repos/top-think/framework/subscribers","subscription_url":"https://api.github.com/repos/top-think/framework/subscription","commits_url":"https://api.github.com/repos/top-think/framework/commits{/sha}","git_commits_url":"https://api.github.com/repos/top-think/framework/git/commits{/sha}","comments_url":"https://api.github.com/repos/top-think/framework/comments{/number}","issue_comment_url":"https://api.github.com/repos/top-think/framework/issues/comments{/number}","contents_url":"https://api.github.com/repos/top-think/framework/contents/{+path}","compare_url":"https://api.github.com/repos/top-think/framework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/top-think/framework/merges","archive_url":"https://api.github.com/repos/top-think/framework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/top-think/framework/downloads","issues_url":"https://api.github.com/repos/top-think/framework/issues{/number}","pulls_url":"https://api.github.com/repos/top-think/framework/pulls{/number}","milestones_url":"https://api.github.com/repos/top-think/framework/milestones{/number}","notifications_url":"https://api.github.com/repos/top-think/framework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/top-think/framework/labels{/name}","releases_url":"https://api.github.com/repos/top-think/framework/releases{/id}","deployments_url":"https://api.github.com/repos/top-think/framework/deployments","created_at":"2015-12-24T07:12:35Z","updated_at":"2016-07-18T00:44:00Z","pushed_at":"2016-07-19T01:59:08Z","git_url":"git://github.com/top-think/framework.git","ssh_url":"git@github.com:top-think/framework.git","clone_url":"https://github.com/top-think/framework.git","svn_url":"https://github.com/top-think/framework","homepage":"","size":8457,"stargazers_count":150,"watchers_count":150,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":123,"mirror_url":null,"open_issues_count":36,"forks":123,"open_issues":36,"watchers":150,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/top-think/framework/pulls/220"},"html":{"href":"https://github.com/top-think/framework/pull/220"},"issue":{"href":"https://api.github.com/repos/top-think/framework/issues/220"},"comments":{"href":"https://api.github.com/repos/top-think/framework/issues/220/comments"},"review_comments":{"href":"https://api.github.com/repos/top-think/framework/pulls/220/comments"},"review_comment":{"href":"https://api.github.com/repos/top-think/framework/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/top-think/framework/pulls/220/commits"},"statuses":{"href":"https://api.github.com/repos/top-think/framework/statuses/98cf1454b5c689651965472eb5400e2c25667549"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":2,"review_comments":3,"commits":2,"additions":8,"deletions":20,"changed_files":1}}
{"actor":{"display_login":"yunwuxin"}}