{"action":"created","comment":{"url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/comments/39154656","id":39154656,"diff_hunk":"@@ -89,19 +91,46 @@ public function add($autodate = true, $null_values = false)\n         return parent::add($autodate, $null_values);\n     }\n \n+    public static function isDisplayHookName($hook_name)\n+    {\n+        $hook_name = strtolower($hook_name);\n+\n+        if ($hook_name === 'header') {\n+            // this hook is to add resources to the <head> section of the page\n+            // so it doesn't display anything by itself\n+            return false;","path":"classes/Hook.php","position":20,"original_position":20,"commit_id":"5406e3d3a906765ab040a6f2590de4496597f408","original_commit_id":"2d8428ab1baa79b3e1bf3dcfc643f27bb016d007","user":{"login":"djfm","id":1460499,"avatar_url":"https://avatars.githubusercontent.com/u/1460499?v=3","gravatar_id":"","url":"https://api.github.com/users/djfm","html_url":"https://github.com/djfm","followers_url":"https://api.github.com/users/djfm/followers","following_url":"https://api.github.com/users/djfm/following{/other_user}","gists_url":"https://api.github.com/users/djfm/gists{/gist_id}","starred_url":"https://api.github.com/users/djfm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djfm/subscriptions","organizations_url":"https://api.github.com/users/djfm/orgs","repos_url":"https://api.github.com/users/djfm/repos","events_url":"https://api.github.com/users/djfm/events{/privacy}","received_events_url":"https://api.github.com/users/djfm/received_events","type":"User","site_admin":false},"body":"Yeah but it won't \"display\" anything so I don't think there is any point in hooking a widget to the header","created_at":"2015-09-10T12:42:01Z","updated_at":"2015-09-10T12:42:01Z","html_url":"https://github.com/PrestaShop/PrestaShop/pull/3952#discussion_r39154656","pull_request_url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952","_links":{"self":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/comments/39154656"},"html":{"href":"https://github.com/PrestaShop/PrestaShop/pull/3952#discussion_r39154656"},"pull_request":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952"}}},"pull_request":{"url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952","id":44643228,"html_url":"https://github.com/PrestaShop/PrestaShop/pull/3952","diff_url":"https://github.com/PrestaShop/PrestaShop/pull/3952.diff","patch_url":"https://github.com/PrestaShop/PrestaShop/pull/3952.patch","issue_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/3952","number":3952,"state":"open","locked":false,"title":"Feat/starter theme widgets","user":{"login":"djfm","id":1460499,"avatar_url":"https://avatars.githubusercontent.com/u/1460499?v=3","gravatar_id":"","url":"https://api.github.com/users/djfm","html_url":"https://github.com/djfm","followers_url":"https://api.github.com/users/djfm/followers","following_url":"https://api.github.com/users/djfm/following{/other_user}","gists_url":"https://api.github.com/users/djfm/gists{/gist_id}","starred_url":"https://api.github.com/users/djfm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djfm/subscriptions","organizations_url":"https://api.github.com/users/djfm/orgs","repos_url":"https://api.github.com/users/djfm/repos","events_url":"https://api.github.com/users/djfm/events{/privacy}","received_events_url":"https://api.github.com/users/djfm/received_events","type":"User","site_admin":false},"body":"This is the beginning of the implementation of the specification described here: https://trello.com/c/pcKZ4qOA/102-widget-system-proposal.\r\n\r\nIn a few words, it allows a module to hook a \"widget\" to any display hook.\r\n\r\nUsage example: PrestaShop/blocklanguages#8\r\n\r\nAlso introducing the `wiget_block` syntax, that you can use like this:\r\n\r\n```smarty\r\n{widget_block name=\"blocklanguages\"}\r\n    <div>\r\n        <div>{$current_language.name}</div>\r\n        {foreach from=$languages item=\"language\"}\r\n            {$language.name}\r\n        {/foreach}\r\n    </div>\r\n{/widget_block}\r\n```\r\n\r\nWhat happens here is that the widget variables are passed to your block so you can override any widget!","created_at":"2015-09-10T09:04:13Z","updated_at":"2015-09-10T12:42:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4c24e1e5636230fa80123ece67b959628b87c513","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952/commits","review_comments_url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952/comments","review_comment_url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/comments{/number}","comments_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/3952/comments","statuses_url":"https://api.github.com/repos/PrestaShop/PrestaShop/statuses/5406e3d3a906765ab040a6f2590de4496597f408","head":{"label":"djfm:feat/starter-theme-widgets","ref":"feat/starter-theme-widgets","sha":"5406e3d3a906765ab040a6f2590de4496597f408","user":{"login":"djfm","id":1460499,"avatar_url":"https://avatars.githubusercontent.com/u/1460499?v=3","gravatar_id":"","url":"https://api.github.com/users/djfm","html_url":"https://github.com/djfm","followers_url":"https://api.github.com/users/djfm/followers","following_url":"https://api.github.com/users/djfm/following{/other_user}","gists_url":"https://api.github.com/users/djfm/gists{/gist_id}","starred_url":"https://api.github.com/users/djfm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djfm/subscriptions","organizations_url":"https://api.github.com/users/djfm/orgs","repos_url":"https://api.github.com/users/djfm/repos","events_url":"https://api.github.com/users/djfm/events{/privacy}","received_events_url":"https://api.github.com/users/djfm/received_events","type":"User","site_admin":false},"repo":{"id":8723586,"name":"PrestaShop","full_name":"djfm/PrestaShop","owner":{"login":"djfm","id":1460499,"avatar_url":"https://avatars.githubusercontent.com/u/1460499?v=3","gravatar_id":"","url":"https://api.github.com/users/djfm","html_url":"https://github.com/djfm","followers_url":"https://api.github.com/users/djfm/followers","following_url":"https://api.github.com/users/djfm/following{/other_user}","gists_url":"https://api.github.com/users/djfm/gists{/gist_id}","starred_url":"https://api.github.com/users/djfm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djfm/subscriptions","organizations_url":"https://api.github.com/users/djfm/orgs","repos_url":"https://api.github.com/users/djfm/repos","events_url":"https://api.github.com/users/djfm/events{/privacy}","received_events_url":"https://api.github.com/users/djfm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/djfm/PrestaShop","description":"PrestaShop offers a free, fully scalable, Open-source e-commerce solution.","fork":true,"url":"https://api.github.com/repos/djfm/PrestaShop","forks_url":"https://api.github.com/repos/djfm/PrestaShop/forks","keys_url":"https://api.github.com/repos/djfm/PrestaShop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/djfm/PrestaShop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/djfm/PrestaShop/teams","hooks_url":"https://api.github.com/repos/djfm/PrestaShop/hooks","issue_events_url":"https://api.github.com/repos/djfm/PrestaShop/issues/events{/number}","events_url":"https://api.github.com/repos/djfm/PrestaShop/events","assignees_url":"https://api.github.com/repos/djfm/PrestaShop/assignees{/user}","branches_url":"https://api.github.com/repos/djfm/PrestaShop/branches{/branch}","tags_url":"https://api.github.com/repos/djfm/PrestaShop/tags","blobs_url":"https://api.github.com/repos/djfm/PrestaShop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/djfm/PrestaShop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/djfm/PrestaShop/git/refs{/sha}","trees_url":"https://api.github.com/repos/djfm/PrestaShop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/djfm/PrestaShop/statuses/{sha}","languages_url":"https://api.github.com/repos/djfm/PrestaShop/languages","stargazers_url":"https://api.github.com/repos/djfm/PrestaShop/stargazers","contributors_url":"https://api.github.com/repos/djfm/PrestaShop/contributors","subscribers_url":"https://api.github.com/repos/djfm/PrestaShop/subscribers","subscription_url":"https://api.github.com/repos/djfm/PrestaShop/subscription","commits_url":"https://api.github.com/repos/djfm/PrestaShop/commits{/sha}","git_commits_url":"https://api.github.com/repos/djfm/PrestaShop/git/commits{/sha}","comments_url":"https://api.github.com/repos/djfm/PrestaShop/comments{/number}","issue_comment_url":"https://api.github.com/repos/djfm/PrestaShop/issues/comments{/number}","contents_url":"https://api.github.com/repos/djfm/PrestaShop/contents/{+path}","compare_url":"https://api.github.com/repos/djfm/PrestaShop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/djfm/PrestaShop/merges","archive_url":"https://api.github.com/repos/djfm/PrestaShop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/djfm/PrestaShop/downloads","issues_url":"https://api.github.com/repos/djfm/PrestaShop/issues{/number}","pulls_url":"https://api.github.com/repos/djfm/PrestaShop/pulls{/number}","milestones_url":"https://api.github.com/repos/djfm/PrestaShop/milestones{/number}","notifications_url":"https://api.github.com/repos/djfm/PrestaShop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/djfm/PrestaShop/labels{/name}","releases_url":"https://api.github.com/repos/djfm/PrestaShop/releases{/id}","created_at":"2013-03-12T08:49:03Z","updated_at":"2014-06-18T08:58:06Z","pushed_at":"2015-09-10T12:35:57Z","git_url":"git://github.com/djfm/PrestaShop.git","ssh_url":"git@github.com:djfm/PrestaShop.git","clone_url":"https://github.com/djfm/PrestaShop.git","svn_url":"https://github.com/djfm/PrestaShop","homepage":"http://www.prestashop.com/","size":212613,"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":"PrestaShop:feat/starter-theme","ref":"feat/starter-theme","sha":"5aef2597e770dfe3a962882350efd24377c69752","user":{"login":"PrestaShop","id":2815696,"avatar_url":"https://avatars.githubusercontent.com/u/2815696?v=3","gravatar_id":"","url":"https://api.github.com/users/PrestaShop","html_url":"https://github.com/PrestaShop","followers_url":"https://api.github.com/users/PrestaShop/followers","following_url":"https://api.github.com/users/PrestaShop/following{/other_user}","gists_url":"https://api.github.com/users/PrestaShop/gists{/gist_id}","starred_url":"https://api.github.com/users/PrestaShop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PrestaShop/subscriptions","organizations_url":"https://api.github.com/users/PrestaShop/orgs","repos_url":"https://api.github.com/users/PrestaShop/repos","events_url":"https://api.github.com/users/PrestaShop/events{/privacy}","received_events_url":"https://api.github.com/users/PrestaShop/received_events","type":"Organization","site_admin":false},"repo":{"id":6763587,"name":"PrestaShop","full_name":"PrestaShop/PrestaShop","owner":{"login":"PrestaShop","id":2815696,"avatar_url":"https://avatars.githubusercontent.com/u/2815696?v=3","gravatar_id":"","url":"https://api.github.com/users/PrestaShop","html_url":"https://github.com/PrestaShop","followers_url":"https://api.github.com/users/PrestaShop/followers","following_url":"https://api.github.com/users/PrestaShop/following{/other_user}","gists_url":"https://api.github.com/users/PrestaShop/gists{/gist_id}","starred_url":"https://api.github.com/users/PrestaShop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PrestaShop/subscriptions","organizations_url":"https://api.github.com/users/PrestaShop/orgs","repos_url":"https://api.github.com/users/PrestaShop/repos","events_url":"https://api.github.com/users/PrestaShop/events{/privacy}","received_events_url":"https://api.github.com/users/PrestaShop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/PrestaShop/PrestaShop","description":"PrestaShop offers a free, fully scalable, Open-source e-commerce solution.","fork":false,"url":"https://api.github.com/repos/PrestaShop/PrestaShop","forks_url":"https://api.github.com/repos/PrestaShop/PrestaShop/forks","keys_url":"https://api.github.com/repos/PrestaShop/PrestaShop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/PrestaShop/PrestaShop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/PrestaShop/PrestaShop/teams","hooks_url":"https://api.github.com/repos/PrestaShop/PrestaShop/hooks","issue_events_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/events{/number}","events_url":"https://api.github.com/repos/PrestaShop/PrestaShop/events","assignees_url":"https://api.github.com/repos/PrestaShop/PrestaShop/assignees{/user}","branches_url":"https://api.github.com/repos/PrestaShop/PrestaShop/branches{/branch}","tags_url":"https://api.github.com/repos/PrestaShop/PrestaShop/tags","blobs_url":"https://api.github.com/repos/PrestaShop/PrestaShop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/PrestaShop/PrestaShop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/PrestaShop/PrestaShop/git/refs{/sha}","trees_url":"https://api.github.com/repos/PrestaShop/PrestaShop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/PrestaShop/PrestaShop/statuses/{sha}","languages_url":"https://api.github.com/repos/PrestaShop/PrestaShop/languages","stargazers_url":"https://api.github.com/repos/PrestaShop/PrestaShop/stargazers","contributors_url":"https://api.github.com/repos/PrestaShop/PrestaShop/contributors","subscribers_url":"https://api.github.com/repos/PrestaShop/PrestaShop/subscribers","subscription_url":"https://api.github.com/repos/PrestaShop/PrestaShop/subscription","commits_url":"https://api.github.com/repos/PrestaShop/PrestaShop/commits{/sha}","git_commits_url":"https://api.github.com/repos/PrestaShop/PrestaShop/git/commits{/sha}","comments_url":"https://api.github.com/repos/PrestaShop/PrestaShop/comments{/number}","issue_comment_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/comments{/number}","contents_url":"https://api.github.com/repos/PrestaShop/PrestaShop/contents/{+path}","compare_url":"https://api.github.com/repos/PrestaShop/PrestaShop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/PrestaShop/PrestaShop/merges","archive_url":"https://api.github.com/repos/PrestaShop/PrestaShop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/PrestaShop/PrestaShop/downloads","issues_url":"https://api.github.com/repos/PrestaShop/PrestaShop/issues{/number}","pulls_url":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls{/number}","milestones_url":"https://api.github.com/repos/PrestaShop/PrestaShop/milestones{/number}","notifications_url":"https://api.github.com/repos/PrestaShop/PrestaShop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/PrestaShop/PrestaShop/labels{/name}","releases_url":"https://api.github.com/repos/PrestaShop/PrestaShop/releases{/id}","created_at":"2012-11-19T16:41:31Z","updated_at":"2015-09-10T10:08:19Z","pushed_at":"2015-09-10T12:35:58Z","git_url":"git://github.com/PrestaShop/PrestaShop.git","ssh_url":"git@github.com:PrestaShop/PrestaShop.git","clone_url":"https://github.com/PrestaShop/PrestaShop.git","svn_url":"https://github.com/PrestaShop/PrestaShop","homepage":"http://www.prestashop.com/","size":316489,"stargazers_count":1391,"watchers_count":1391,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1560,"mirror_url":null,"open_issues_count":434,"forks":1560,"open_issues":434,"watchers":1391,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952"},"html":{"href":"https://github.com/PrestaShop/PrestaShop/pull/3952"},"issue":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/3952"},"comments":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/issues/3952/comments"},"review_comments":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952/comments"},"review_comment":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/pulls/3952/commits"},"statuses":{"href":"https://api.github.com/repos/PrestaShop/PrestaShop/statuses/5406e3d3a906765ab040a6f2590de4496597f408"}}}}