{"action":"created","comment":{"url":"https://api.github.com/repos/codex-team/codex/pulls/comments/47998085","id":47998085,"diff_hunk":"@@ -183,12 +191,16 @@ private static function getArticles($add_not_published = false, $add_removed = f\n     {\n         $articlesQuery = Dao_Articles::select()->limit(200);        // TODO(#40) add pagination.\n \n-        if (!$add_removed) {\n-            $articlesQuery->where('is_removed', '=', false);\n+        if ($add_removed && !$add_not_published) {\n+            $articlesQuery->where('is_removed', '=', true);\n+        }\n+\n+        if (!$add_removed && $add_not_published) {\n+            $articlesQuery->where('is_published', '=', false);\n         }\n \n-        if (!$add_not_published) {\n-            $articlesQuery->where('is_published', '=', true);\n+        if (!$add_removed && !$add_not_published) {\n+            $articlesQuery->where('is_removed', '=', false, 'and', 'is_published', '=', true);","path":"application/classes/Model/Article.php","position":37,"original_position":37,"commit_id":"b4c7ab2437b9293fce9d883b48c70715366e9b0b","original_commit_id":"b4c7ab2437b9293fce9d883b48c70715366e9b0b","user":{"login":"eliseealex","id":4640201,"avatar_url":"https://avatars.githubusercontent.com/u/4640201?v=3","gravatar_id":"","url":"https://api.github.com/users/eliseealex","html_url":"https://github.com/eliseealex","followers_url":"https://api.github.com/users/eliseealex/followers","following_url":"https://api.github.com/users/eliseealex/following{/other_user}","gists_url":"https://api.github.com/users/eliseealex/gists{/gist_id}","starred_url":"https://api.github.com/users/eliseealex/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eliseealex/subscriptions","organizations_url":"https://api.github.com/users/eliseealex/orgs","repos_url":"https://api.github.com/users/eliseealex/repos","events_url":"https://api.github.com/users/eliseealex/events{/privacy}","received_events_url":"https://api.github.com/users/eliseealex/received_events","type":"User","site_admin":false},"body":"Это не будет работать","created_at":"2015-12-18T06:33:05Z","updated_at":"2015-12-18T06:33:05Z","html_url":"https://github.com/codex-team/codex/pull/90#discussion_r47998085","pull_request_url":"https://api.github.com/repos/codex-team/codex/pulls/90","_links":{"self":{"href":"https://api.github.com/repos/codex-team/codex/pulls/comments/47998085"},"html":{"href":"https://github.com/codex-team/codex/pull/90#discussion_r47998085"},"pull_request":{"href":"https://api.github.com/repos/codex-team/codex/pulls/90"}}},"pull_request":{"url":"https://api.github.com/repos/codex-team/codex/pulls/90","id":54059867,"html_url":"https://github.com/codex-team/codex/pull/90","diff_url":"https://github.com/codex-team/codex/pull/90.diff","patch_url":"https://github.com/codex-team/codex/pull/90.patch","issue_url":"https://api.github.com/repos/codex-team/codex/issues/90","number":90,"state":"open","locked":false,"title":"Deleted and unpublished #39","user":{"login":"ivanszhuravlev","id":14206477,"avatar_url":"https://avatars.githubusercontent.com/u/14206477?v=3","gravatar_id":"","url":"https://api.github.com/users/ivanszhuravlev","html_url":"https://github.com/ivanszhuravlev","followers_url":"https://api.github.com/users/ivanszhuravlev/followers","following_url":"https://api.github.com/users/ivanszhuravlev/following{/other_user}","gists_url":"https://api.github.com/users/ivanszhuravlev/gists{/gist_id}","starred_url":"https://api.github.com/users/ivanszhuravlev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivanszhuravlev/subscriptions","organizations_url":"https://api.github.com/users/ivanszhuravlev/orgs","repos_url":"https://api.github.com/users/ivanszhuravlev/repos","events_url":"https://api.github.com/users/ivanszhuravlev/events{/privacy}","received_events_url":"https://api.github.com/users/ivanszhuravlev/received_events","type":"User","site_admin":false},"body":"- [ ] @eliseealex \r\n- [ ] @neSpecc \r\n- [ ] @n0str \r\n- [ ] @Markus3295 \r\n- [ ] @illiiiillllilii \r\n- [ ] @loopdigga98 ","created_at":"2015-12-18T02:57:49Z","updated_at":"2015-12-18T06:33:05Z","closed_at":null,"merged_at":null,"merge_commit_sha":"845102b4c5b4f7e1dab10f3818e1e15fce4f5fad","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/codex-team/codex/pulls/90/commits","review_comments_url":"https://api.github.com/repos/codex-team/codex/pulls/90/comments","review_comment_url":"https://api.github.com/repos/codex-team/codex/pulls/comments{/number}","comments_url":"https://api.github.com/repos/codex-team/codex/issues/90/comments","statuses_url":"https://api.github.com/repos/codex-team/codex/statuses/b4c7ab2437b9293fce9d883b48c70715366e9b0b","head":{"label":"codex-team:deleted-and-unpublished-#39","ref":"deleted-and-unpublished-#39","sha":"b4c7ab2437b9293fce9d883b48c70715366e9b0b","user":{"login":"codex-team","id":16060815,"avatar_url":"https://avatars.githubusercontent.com/u/16060815?v=3","gravatar_id":"","url":"https://api.github.com/users/codex-team","html_url":"https://github.com/codex-team","followers_url":"https://api.github.com/users/codex-team/followers","following_url":"https://api.github.com/users/codex-team/following{/other_user}","gists_url":"https://api.github.com/users/codex-team/gists{/gist_id}","starred_url":"https://api.github.com/users/codex-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codex-team/subscriptions","organizations_url":"https://api.github.com/users/codex-team/orgs","repos_url":"https://api.github.com/users/codex-team/repos","events_url":"https://api.github.com/users/codex-team/events{/privacy}","received_events_url":"https://api.github.com/users/codex-team/received_events","type":"Organization","site_admin":false},"repo":{"id":44992775,"name":"codex","full_name":"codex-team/codex","owner":{"login":"codex-team","id":16060815,"avatar_url":"https://avatars.githubusercontent.com/u/16060815?v=3","gravatar_id":"","url":"https://api.github.com/users/codex-team","html_url":"https://github.com/codex-team","followers_url":"https://api.github.com/users/codex-team/followers","following_url":"https://api.github.com/users/codex-team/following{/other_user}","gists_url":"https://api.github.com/users/codex-team/gists{/gist_id}","starred_url":"https://api.github.com/users/codex-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codex-team/subscriptions","organizations_url":"https://api.github.com/users/codex-team/orgs","repos_url":"https://api.github.com/users/codex-team/repos","events_url":"https://api.github.com/users/codex-team/events{/privacy}","received_events_url":"https://api.github.com/users/codex-team/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codex-team/codex","description":"Codex Team development","fork":false,"url":"https://api.github.com/repos/codex-team/codex","forks_url":"https://api.github.com/repos/codex-team/codex/forks","keys_url":"https://api.github.com/repos/codex-team/codex/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codex-team/codex/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codex-team/codex/teams","hooks_url":"https://api.github.com/repos/codex-team/codex/hooks","issue_events_url":"https://api.github.com/repos/codex-team/codex/issues/events{/number}","events_url":"https://api.github.com/repos/codex-team/codex/events","assignees_url":"https://api.github.com/repos/codex-team/codex/assignees{/user}","branches_url":"https://api.github.com/repos/codex-team/codex/branches{/branch}","tags_url":"https://api.github.com/repos/codex-team/codex/tags","blobs_url":"https://api.github.com/repos/codex-team/codex/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codex-team/codex/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codex-team/codex/git/refs{/sha}","trees_url":"https://api.github.com/repos/codex-team/codex/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codex-team/codex/statuses/{sha}","languages_url":"https://api.github.com/repos/codex-team/codex/languages","stargazers_url":"https://api.github.com/repos/codex-team/codex/stargazers","contributors_url":"https://api.github.com/repos/codex-team/codex/contributors","subscribers_url":"https://api.github.com/repos/codex-team/codex/subscribers","subscription_url":"https://api.github.com/repos/codex-team/codex/subscription","commits_url":"https://api.github.com/repos/codex-team/codex/commits{/sha}","git_commits_url":"https://api.github.com/repos/codex-team/codex/git/commits{/sha}","comments_url":"https://api.github.com/repos/codex-team/codex/comments{/number}","issue_comment_url":"https://api.github.com/repos/codex-team/codex/issues/comments{/number}","contents_url":"https://api.github.com/repos/codex-team/codex/contents/{+path}","compare_url":"https://api.github.com/repos/codex-team/codex/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codex-team/codex/merges","archive_url":"https://api.github.com/repos/codex-team/codex/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codex-team/codex/downloads","issues_url":"https://api.github.com/repos/codex-team/codex/issues{/number}","pulls_url":"https://api.github.com/repos/codex-team/codex/pulls{/number}","milestones_url":"https://api.github.com/repos/codex-team/codex/milestones{/number}","notifications_url":"https://api.github.com/repos/codex-team/codex/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codex-team/codex/labels{/name}","releases_url":"https://api.github.com/repos/codex-team/codex/releases{/id}","created_at":"2015-10-26T19:41:35Z","updated_at":"2015-11-28T17:09:25Z","pushed_at":"2015-12-18T06:06:17Z","git_url":"git://github.com/codex-team/codex.git","ssh_url":"git@github.com:codex-team/codex.git","clone_url":"https://github.com/codex-team/codex.git","svn_url":"https://github.com/codex-team/codex","homepage":"http://alpha.difual.com","size":9696,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":20,"forks":5,"open_issues":20,"watchers":0,"default_branch":"master"}},"base":{"label":"codex-team:master","ref":"master","sha":"52a58706d2b0367dc84fcad05d356a5a59ea678f","user":{"login":"codex-team","id":16060815,"avatar_url":"https://avatars.githubusercontent.com/u/16060815?v=3","gravatar_id":"","url":"https://api.github.com/users/codex-team","html_url":"https://github.com/codex-team","followers_url":"https://api.github.com/users/codex-team/followers","following_url":"https://api.github.com/users/codex-team/following{/other_user}","gists_url":"https://api.github.com/users/codex-team/gists{/gist_id}","starred_url":"https://api.github.com/users/codex-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codex-team/subscriptions","organizations_url":"https://api.github.com/users/codex-team/orgs","repos_url":"https://api.github.com/users/codex-team/repos","events_url":"https://api.github.com/users/codex-team/events{/privacy}","received_events_url":"https://api.github.com/users/codex-team/received_events","type":"Organization","site_admin":false},"repo":{"id":44992775,"name":"codex","full_name":"codex-team/codex","owner":{"login":"codex-team","id":16060815,"avatar_url":"https://avatars.githubusercontent.com/u/16060815?v=3","gravatar_id":"","url":"https://api.github.com/users/codex-team","html_url":"https://github.com/codex-team","followers_url":"https://api.github.com/users/codex-team/followers","following_url":"https://api.github.com/users/codex-team/following{/other_user}","gists_url":"https://api.github.com/users/codex-team/gists{/gist_id}","starred_url":"https://api.github.com/users/codex-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codex-team/subscriptions","organizations_url":"https://api.github.com/users/codex-team/orgs","repos_url":"https://api.github.com/users/codex-team/repos","events_url":"https://api.github.com/users/codex-team/events{/privacy}","received_events_url":"https://api.github.com/users/codex-team/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codex-team/codex","description":"Codex Team development","fork":false,"url":"https://api.github.com/repos/codex-team/codex","forks_url":"https://api.github.com/repos/codex-team/codex/forks","keys_url":"https://api.github.com/repos/codex-team/codex/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codex-team/codex/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codex-team/codex/teams","hooks_url":"https://api.github.com/repos/codex-team/codex/hooks","issue_events_url":"https://api.github.com/repos/codex-team/codex/issues/events{/number}","events_url":"https://api.github.com/repos/codex-team/codex/events","assignees_url":"https://api.github.com/repos/codex-team/codex/assignees{/user}","branches_url":"https://api.github.com/repos/codex-team/codex/branches{/branch}","tags_url":"https://api.github.com/repos/codex-team/codex/tags","blobs_url":"https://api.github.com/repos/codex-team/codex/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codex-team/codex/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codex-team/codex/git/refs{/sha}","trees_url":"https://api.github.com/repos/codex-team/codex/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codex-team/codex/statuses/{sha}","languages_url":"https://api.github.com/repos/codex-team/codex/languages","stargazers_url":"https://api.github.com/repos/codex-team/codex/stargazers","contributors_url":"https://api.github.com/repos/codex-team/codex/contributors","subscribers_url":"https://api.github.com/repos/codex-team/codex/subscribers","subscription_url":"https://api.github.com/repos/codex-team/codex/subscription","commits_url":"https://api.github.com/repos/codex-team/codex/commits{/sha}","git_commits_url":"https://api.github.com/repos/codex-team/codex/git/commits{/sha}","comments_url":"https://api.github.com/repos/codex-team/codex/comments{/number}","issue_comment_url":"https://api.github.com/repos/codex-team/codex/issues/comments{/number}","contents_url":"https://api.github.com/repos/codex-team/codex/contents/{+path}","compare_url":"https://api.github.com/repos/codex-team/codex/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codex-team/codex/merges","archive_url":"https://api.github.com/repos/codex-team/codex/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codex-team/codex/downloads","issues_url":"https://api.github.com/repos/codex-team/codex/issues{/number}","pulls_url":"https://api.github.com/repos/codex-team/codex/pulls{/number}","milestones_url":"https://api.github.com/repos/codex-team/codex/milestones{/number}","notifications_url":"https://api.github.com/repos/codex-team/codex/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codex-team/codex/labels{/name}","releases_url":"https://api.github.com/repos/codex-team/codex/releases{/id}","created_at":"2015-10-26T19:41:35Z","updated_at":"2015-11-28T17:09:25Z","pushed_at":"2015-12-18T06:06:17Z","git_url":"git://github.com/codex-team/codex.git","ssh_url":"git@github.com:codex-team/codex.git","clone_url":"https://github.com/codex-team/codex.git","svn_url":"https://github.com/codex-team/codex","homepage":"http://alpha.difual.com","size":9696,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":20,"forks":5,"open_issues":20,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/codex-team/codex/pulls/90"},"html":{"href":"https://github.com/codex-team/codex/pull/90"},"issue":{"href":"https://api.github.com/repos/codex-team/codex/issues/90"},"comments":{"href":"https://api.github.com/repos/codex-team/codex/issues/90/comments"},"review_comments":{"href":"https://api.github.com/repos/codex-team/codex/pulls/90/comments"},"review_comment":{"href":"https://api.github.com/repos/codex-team/codex/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/codex-team/codex/pulls/90/commits"},"statuses":{"href":"https://api.github.com/repos/codex-team/codex/statuses/b4c7ab2437b9293fce9d883b48c70715366e9b0b"}}}}