{"action":"created","comment":{"url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/comments/42212884","id":42212884,"diff_hunk":"@@ -327,7 +328,12 @@ public function highlightSqlSyntax($sql)\n         \\SqlFormatter::$comment_attributes = 'class=\"comment\"';\n         \\SqlFormatter::$variable_attributes = 'class=\"variable\"';\n \n-        $html = \\SqlFormatter::highlight($sql);\n+        if ($highlightOnly) {\n+            $html = \\SqlFormatter::highlight($sql);\n+        } else {\n+            $html = \\SqlFormatter::format($sql);\n+        }\n+\n         $html = preg_replace('/<pre class=\"(.*)\">([^\"]*+)<\\/pre>/Us', '<div class=\"\\1\"><pre>\\2</pre></div>', $html);","path":"Twig/DoctrineExtension.php","position":null,"original_position":39,"commit_id":"8087a311e1bbd00efc18a6ce57b5ade4b5748620","original_commit_id":"3010bb0418ddc86b6faa20bf639b25ef6a700460","user":{"login":"javiereguiluz","id":73419,"avatar_url":"https://avatars.githubusercontent.com/u/73419?v=3","gravatar_id":"","url":"https://api.github.com/users/javiereguiluz","html_url":"https://github.com/javiereguiluz","followers_url":"https://api.github.com/users/javiereguiluz/followers","following_url":"https://api.github.com/users/javiereguiluz/following{/other_user}","gists_url":"https://api.github.com/users/javiereguiluz/gists{/gist_id}","starred_url":"https://api.github.com/users/javiereguiluz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javiereguiluz/subscriptions","organizations_url":"https://api.github.com/users/javiereguiluz/orgs","repos_url":"https://api.github.com/users/javiereguiluz/repos","events_url":"https://api.github.com/users/javiereguiluz/events{/privacy}","received_events_url":"https://api.github.com/users/javiereguiluz/received_events","type":"User","site_admin":false},"body":"We can't use `$use_pre` because is a \"global state\" and we need to output different things depending whther we highlight or not. I've just updated the code.","created_at":"2015-10-16T06:42:03Z","updated_at":"2015-10-16T06:42:03Z","html_url":"https://github.com/doctrine/DoctrineBundle/pull/477#discussion_r42212884","pull_request_url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477","_links":{"self":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/comments/42212884"},"html":{"href":"https://github.com/doctrine/DoctrineBundle/pull/477#discussion_r42212884"},"pull_request":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477"}}},"pull_request":{"url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477","id":47818170,"html_url":"https://github.com/doctrine/DoctrineBundle/pull/477","diff_url":"https://github.com/doctrine/DoctrineBundle/pull/477.diff","patch_url":"https://github.com/doctrine/DoctrineBundle/pull/477.patch","issue_url":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/477","number":477,"state":"open","locked":false,"title":"Refactored the doctrine_pretty_query filter to support \"highlight only\" mode","user":{"login":"javiereguiluz","id":73419,"avatar_url":"https://avatars.githubusercontent.com/u/73419?v=3","gravatar_id":"","url":"https://api.github.com/users/javiereguiluz","html_url":"https://github.com/javiereguiluz","followers_url":"https://api.github.com/users/javiereguiluz/followers","following_url":"https://api.github.com/users/javiereguiluz/following{/other_user}","gists_url":"https://api.github.com/users/javiereguiluz/gists{/gist_id}","starred_url":"https://api.github.com/users/javiereguiluz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javiereguiluz/subscriptions","organizations_url":"https://api.github.com/users/javiereguiluz/orgs","repos_url":"https://api.github.com/users/javiereguiluz/repos","events_url":"https://api.github.com/users/javiereguiluz/events{/privacy}","received_events_url":"https://api.github.com/users/javiereguiluz/received_events","type":"User","site_admin":false},"body":"This fixes #469","created_at":"2015-10-15T17:41:40Z","updated_at":"2015-10-16T06:42:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d042fd6021338c3b6566f1ae4428f232a35c86f7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477/commits","review_comments_url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477/comments","review_comment_url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/comments{/number}","comments_url":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/477/comments","statuses_url":"https://api.github.com/repos/doctrine/DoctrineBundle/statuses/8087a311e1bbd00efc18a6ce57b5ade4b5748620","head":{"label":"javiereguiluz:fix_469","ref":"fix_469","sha":"8087a311e1bbd00efc18a6ce57b5ade4b5748620","user":{"login":"javiereguiluz","id":73419,"avatar_url":"https://avatars.githubusercontent.com/u/73419?v=3","gravatar_id":"","url":"https://api.github.com/users/javiereguiluz","html_url":"https://github.com/javiereguiluz","followers_url":"https://api.github.com/users/javiereguiluz/followers","following_url":"https://api.github.com/users/javiereguiluz/following{/other_user}","gists_url":"https://api.github.com/users/javiereguiluz/gists{/gist_id}","starred_url":"https://api.github.com/users/javiereguiluz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javiereguiluz/subscriptions","organizations_url":"https://api.github.com/users/javiereguiluz/orgs","repos_url":"https://api.github.com/users/javiereguiluz/repos","events_url":"https://api.github.com/users/javiereguiluz/events{/privacy}","received_events_url":"https://api.github.com/users/javiereguiluz/received_events","type":"User","site_admin":false},"repo":{"id":29480872,"name":"DoctrineBundle","full_name":"javiereguiluz/DoctrineBundle","owner":{"login":"javiereguiluz","id":73419,"avatar_url":"https://avatars.githubusercontent.com/u/73419?v=3","gravatar_id":"","url":"https://api.github.com/users/javiereguiluz","html_url":"https://github.com/javiereguiluz","followers_url":"https://api.github.com/users/javiereguiluz/followers","following_url":"https://api.github.com/users/javiereguiluz/following{/other_user}","gists_url":"https://api.github.com/users/javiereguiluz/gists{/gist_id}","starred_url":"https://api.github.com/users/javiereguiluz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javiereguiluz/subscriptions","organizations_url":"https://api.github.com/users/javiereguiluz/orgs","repos_url":"https://api.github.com/users/javiereguiluz/repos","events_url":"https://api.github.com/users/javiereguiluz/events{/privacy}","received_events_url":"https://api.github.com/users/javiereguiluz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/javiereguiluz/DoctrineBundle","description":"Symfony2 Bundle for Doctrine","fork":true,"url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle","forks_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/forks","keys_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/teams","hooks_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/hooks","issue_events_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/issues/events{/number}","events_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/events","assignees_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/assignees{/user}","branches_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/branches{/branch}","tags_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/tags","blobs_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/git/refs{/sha}","trees_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/statuses/{sha}","languages_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/languages","stargazers_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/stargazers","contributors_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/contributors","subscribers_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/subscribers","subscription_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/subscription","commits_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/commits{/sha}","git_commits_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/git/commits{/sha}","comments_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/comments{/number}","issue_comment_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/issues/comments{/number}","contents_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/contents/{+path}","compare_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/merges","archive_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/downloads","issues_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/issues{/number}","pulls_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/pulls{/number}","milestones_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/milestones{/number}","notifications_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/labels{/name}","releases_url":"https://api.github.com/repos/javiereguiluz/DoctrineBundle/releases{/id}","created_at":"2015-01-19T16:49:07Z","updated_at":"2015-01-19T16:49:08Z","pushed_at":"2015-10-16T06:40:53Z","git_url":"git://github.com/javiereguiluz/DoctrineBundle.git","ssh_url":"git@github.com:javiereguiluz/DoctrineBundle.git","clone_url":"https://github.com/javiereguiluz/DoctrineBundle.git","svn_url":"https://github.com/javiereguiluz/DoctrineBundle","homepage":"http://www.doctrine-project.org/jira","size":1646,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"doctrine:master","ref":"master","sha":"5674222e181c9236abdabed19fc660f35619d82c","user":{"login":"doctrine","id":209254,"avatar_url":"https://avatars.githubusercontent.com/u/209254?v=3","gravatar_id":"","url":"https://api.github.com/users/doctrine","html_url":"https://github.com/doctrine","followers_url":"https://api.github.com/users/doctrine/followers","following_url":"https://api.github.com/users/doctrine/following{/other_user}","gists_url":"https://api.github.com/users/doctrine/gists{/gist_id}","starred_url":"https://api.github.com/users/doctrine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/doctrine/subscriptions","organizations_url":"https://api.github.com/users/doctrine/orgs","repos_url":"https://api.github.com/users/doctrine/repos","events_url":"https://api.github.com/users/doctrine/events{/privacy}","received_events_url":"https://api.github.com/users/doctrine/received_events","type":"Organization","site_admin":false},"repo":{"id":2797951,"name":"DoctrineBundle","full_name":"doctrine/DoctrineBundle","owner":{"login":"doctrine","id":209254,"avatar_url":"https://avatars.githubusercontent.com/u/209254?v=3","gravatar_id":"","url":"https://api.github.com/users/doctrine","html_url":"https://github.com/doctrine","followers_url":"https://api.github.com/users/doctrine/followers","following_url":"https://api.github.com/users/doctrine/following{/other_user}","gists_url":"https://api.github.com/users/doctrine/gists{/gist_id}","starred_url":"https://api.github.com/users/doctrine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/doctrine/subscriptions","organizations_url":"https://api.github.com/users/doctrine/orgs","repos_url":"https://api.github.com/users/doctrine/repos","events_url":"https://api.github.com/users/doctrine/events{/privacy}","received_events_url":"https://api.github.com/users/doctrine/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/doctrine/DoctrineBundle","description":"Symfony2 Bundle for Doctrine","fork":false,"url":"https://api.github.com/repos/doctrine/DoctrineBundle","forks_url":"https://api.github.com/repos/doctrine/DoctrineBundle/forks","keys_url":"https://api.github.com/repos/doctrine/DoctrineBundle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/doctrine/DoctrineBundle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/doctrine/DoctrineBundle/teams","hooks_url":"https://api.github.com/repos/doctrine/DoctrineBundle/hooks","issue_events_url":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/events{/number}","events_url":"https://api.github.com/repos/doctrine/DoctrineBundle/events","assignees_url":"https://api.github.com/repos/doctrine/DoctrineBundle/assignees{/user}","branches_url":"https://api.github.com/repos/doctrine/DoctrineBundle/branches{/branch}","tags_url":"https://api.github.com/repos/doctrine/DoctrineBundle/tags","blobs_url":"https://api.github.com/repos/doctrine/DoctrineBundle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/doctrine/DoctrineBundle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/doctrine/DoctrineBundle/git/refs{/sha}","trees_url":"https://api.github.com/repos/doctrine/DoctrineBundle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/doctrine/DoctrineBundle/statuses/{sha}","languages_url":"https://api.github.com/repos/doctrine/DoctrineBundle/languages","stargazers_url":"https://api.github.com/repos/doctrine/DoctrineBundle/stargazers","contributors_url":"https://api.github.com/repos/doctrine/DoctrineBundle/contributors","subscribers_url":"https://api.github.com/repos/doctrine/DoctrineBundle/subscribers","subscription_url":"https://api.github.com/repos/doctrine/DoctrineBundle/subscription","commits_url":"https://api.github.com/repos/doctrine/DoctrineBundle/commits{/sha}","git_commits_url":"https://api.github.com/repos/doctrine/DoctrineBundle/git/commits{/sha}","comments_url":"https://api.github.com/repos/doctrine/DoctrineBundle/comments{/number}","issue_comment_url":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/comments{/number}","contents_url":"https://api.github.com/repos/doctrine/DoctrineBundle/contents/{+path}","compare_url":"https://api.github.com/repos/doctrine/DoctrineBundle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/doctrine/DoctrineBundle/merges","archive_url":"https://api.github.com/repos/doctrine/DoctrineBundle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/doctrine/DoctrineBundle/downloads","issues_url":"https://api.github.com/repos/doctrine/DoctrineBundle/issues{/number}","pulls_url":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls{/number}","milestones_url":"https://api.github.com/repos/doctrine/DoctrineBundle/milestones{/number}","notifications_url":"https://api.github.com/repos/doctrine/DoctrineBundle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/doctrine/DoctrineBundle/labels{/name}","releases_url":"https://api.github.com/repos/doctrine/DoctrineBundle/releases{/id}","created_at":"2011-11-17T19:25:50Z","updated_at":"2015-10-14T09:23:56Z","pushed_at":"2015-10-16T06:40:53Z","git_url":"git://github.com/doctrine/DoctrineBundle.git","ssh_url":"git@github.com:doctrine/DoctrineBundle.git","clone_url":"https://github.com/doctrine/DoctrineBundle.git","svn_url":"https://github.com/doctrine/DoctrineBundle","homepage":"http://www.doctrine-project.org/jira","size":3028,"stargazers_count":177,"watchers_count":177,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":182,"mirror_url":null,"open_issues_count":83,"forks":182,"open_issues":83,"watchers":177,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477"},"html":{"href":"https://github.com/doctrine/DoctrineBundle/pull/477"},"issue":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/477"},"comments":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/issues/477/comments"},"review_comments":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477/comments"},"review_comment":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/pulls/477/commits"},"statuses":{"href":"https://api.github.com/repos/doctrine/DoctrineBundle/statuses/8087a311e1bbd00efc18a6ce57b5ade4b5748620"}}}}