{"action":"created","comment":{"url":"https://api.github.com/repos/Elgg/Elgg/pulls/comments/33788505","id":33788505,"diff_hunk":"@@ -18,7 +18,8 @@ function likes_init() {\n \telgg_register_plugin_hook_handler('register', 'menu:river', 'likes_river_menu_setup', 400);\n \telgg_register_plugin_hook_handler('register', 'menu:entity', 'likes_entity_menu_setup', 400);\n \telgg_register_plugin_hook_handler('permissions_check', 'annotation', 'likes_permissions_check');\n-\n+\telgg_register_plugin_hook_handler('permissions_check:annotate', 'all', 'likes_permissions_check_annotate', 0);","path":"mod/likes/start.php","position":5,"original_position":5,"commit_id":"bfd3e27ab89730920b8b683907cf59abec12a890","original_commit_id":"bfd3e27ab89730920b8b683907cf59abec12a890","user":{"login":"mrclay","id":170687,"avatar_url":"https://avatars.githubusercontent.com/u/170687?v=3","gravatar_id":"","url":"https://api.github.com/users/mrclay","html_url":"https://github.com/mrclay","followers_url":"https://api.github.com/users/mrclay/followers","following_url":"https://api.github.com/users/mrclay/following{/other_user}","gists_url":"https://api.github.com/users/mrclay/gists{/gist_id}","starred_url":"https://api.github.com/users/mrclay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrclay/subscriptions","organizations_url":"https://api.github.com/users/mrclay/orgs","repos_url":"https://api.github.com/users/mrclay/repos","events_url":"https://api.github.com/users/mrclay/events{/privacy}","received_events_url":"https://api.github.com/users/mrclay/received_events","type":"User","site_admin":false},"body":"Ideally this can become:\r\n```php\r\nelgg_register_plugin_hook_handler('permissions_check:annotate:likes', 'all', 'Elgg\\Values::getFalse', 0);\r\n```","created_at":"2015-07-02T15:18:36Z","updated_at":"2015-07-02T15:18:36Z","html_url":"https://github.com/Elgg/Elgg/pull/8654#discussion_r33788505","pull_request_url":"https://api.github.com/repos/Elgg/Elgg/pulls/8654","_links":{"self":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/comments/33788505"},"html":{"href":"https://github.com/Elgg/Elgg/pull/8654#discussion_r33788505"},"pull_request":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/8654"}}},"pull_request":{"url":"https://api.github.com/repos/Elgg/Elgg/pulls/8654","id":38982993,"html_url":"https://github.com/Elgg/Elgg/pull/8654","diff_url":"https://github.com/Elgg/Elgg/pull/8654.diff","patch_url":"https://github.com/Elgg/Elgg/pull/8654.patch","issue_url":"https://api.github.com/repos/Elgg/Elgg/issues/8654","number":8654,"state":"open","locked":false,"title":"WIP feature(likes): entities are not likeable by default","user":{"login":"jdalsem","id":861833,"avatar_url":"https://avatars.githubusercontent.com/u/861833?v=3","gravatar_id":"","url":"https://api.github.com/users/jdalsem","html_url":"https://github.com/jdalsem","followers_url":"https://api.github.com/users/jdalsem/followers","following_url":"https://api.github.com/users/jdalsem/following{/other_user}","gists_url":"https://api.github.com/users/jdalsem/gists{/gist_id}","starred_url":"https://api.github.com/users/jdalsem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdalsem/subscriptions","organizations_url":"https://api.github.com/users/jdalsem/orgs","repos_url":"https://api.github.com/users/jdalsem/repos","events_url":"https://api.github.com/users/jdalsem/events{/privacy}","received_events_url":"https://api.github.com/users/jdalsem/received_events","type":"User","site_admin":false},"body":"BREAKING CHANGE:\r\nIf you want to allow likes on your content you will have to register a\r\n'permissions_check:annotate' hook to allow like annotations. Core\r\ncontent plugins have been adjusted to provide these hooks.\r\n\r\nfixes #5996 \r\n\r\n\r\nNeed feedback on the blog hook... if that is ok, then i will copy that approach to the other plugins\r\n\r\n- [ ] copy \"allow likes\" hook to groups, blog, bookmarks, file, pages, thewire, discussions and comments\r\n- [ ] add upgrading docs","created_at":"2015-07-01T13:41:06Z","updated_at":"2015-07-02T15:18:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"05a222106022e60ab7162412e028ffef9d09d1ba","assignee":null,"milestone":{"url":"https://api.github.com/repos/Elgg/Elgg/milestones/60","html_url":"https://github.com/Elgg/Elgg/milestones/Elgg%202.0.x","labels_url":"https://api.github.com/repos/Elgg/Elgg/milestones/60/labels","id":404754,"number":60,"title":"Elgg 2.0.x","description":"","creator":{"login":"ewinslow","id":356564,"avatar_url":"https://avatars.githubusercontent.com/u/356564?v=3","gravatar_id":"","url":"https://api.github.com/users/ewinslow","html_url":"https://github.com/ewinslow","followers_url":"https://api.github.com/users/ewinslow/followers","following_url":"https://api.github.com/users/ewinslow/following{/other_user}","gists_url":"https://api.github.com/users/ewinslow/gists{/gist_id}","starred_url":"https://api.github.com/users/ewinslow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ewinslow/subscriptions","organizations_url":"https://api.github.com/users/ewinslow/orgs","repos_url":"https://api.github.com/users/ewinslow/repos","events_url":"https://api.github.com/users/ewinslow/events{/privacy}","received_events_url":"https://api.github.com/users/ewinslow/received_events","type":"User","site_admin":false},"open_issues":15,"closed_issues":62,"state":"open","created_at":"2013-08-19T00:23:53Z","updated_at":"2015-07-02T12:38:06Z","due_on":"2015-07-05T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/Elgg/Elgg/pulls/8654/commits","review_comments_url":"https://api.github.com/repos/Elgg/Elgg/pulls/8654/comments","review_comment_url":"https://api.github.com/repos/Elgg/Elgg/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Elgg/Elgg/issues/8654/comments","statuses_url":"https://api.github.com/repos/Elgg/Elgg/statuses/bfd3e27ab89730920b8b683907cf59abec12a890","head":{"label":"jdalsem:default-unlikeable","ref":"default-unlikeable","sha":"bfd3e27ab89730920b8b683907cf59abec12a890","user":{"login":"jdalsem","id":861833,"avatar_url":"https://avatars.githubusercontent.com/u/861833?v=3","gravatar_id":"","url":"https://api.github.com/users/jdalsem","html_url":"https://github.com/jdalsem","followers_url":"https://api.github.com/users/jdalsem/followers","following_url":"https://api.github.com/users/jdalsem/following{/other_user}","gists_url":"https://api.github.com/users/jdalsem/gists{/gist_id}","starred_url":"https://api.github.com/users/jdalsem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdalsem/subscriptions","organizations_url":"https://api.github.com/users/jdalsem/orgs","repos_url":"https://api.github.com/users/jdalsem/repos","events_url":"https://api.github.com/users/jdalsem/events{/privacy}","received_events_url":"https://api.github.com/users/jdalsem/received_events","type":"User","site_admin":false},"repo":{"id":3067967,"name":"Elgg","full_name":"jdalsem/Elgg","owner":{"login":"jdalsem","id":861833,"avatar_url":"https://avatars.githubusercontent.com/u/861833?v=3","gravatar_id":"","url":"https://api.github.com/users/jdalsem","html_url":"https://github.com/jdalsem","followers_url":"https://api.github.com/users/jdalsem/followers","following_url":"https://api.github.com/users/jdalsem/following{/other_user}","gists_url":"https://api.github.com/users/jdalsem/gists{/gist_id}","starred_url":"https://api.github.com/users/jdalsem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdalsem/subscriptions","organizations_url":"https://api.github.com/users/jdalsem/orgs","repos_url":"https://api.github.com/users/jdalsem/repos","events_url":"https://api.github.com/users/jdalsem/events{/privacy}","received_events_url":"https://api.github.com/users/jdalsem/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jdalsem/Elgg","description":"A social networking engine","fork":true,"url":"https://api.github.com/repos/jdalsem/Elgg","forks_url":"https://api.github.com/repos/jdalsem/Elgg/forks","keys_url":"https://api.github.com/repos/jdalsem/Elgg/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jdalsem/Elgg/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jdalsem/Elgg/teams","hooks_url":"https://api.github.com/repos/jdalsem/Elgg/hooks","issue_events_url":"https://api.github.com/repos/jdalsem/Elgg/issues/events{/number}","events_url":"https://api.github.com/repos/jdalsem/Elgg/events","assignees_url":"https://api.github.com/repos/jdalsem/Elgg/assignees{/user}","branches_url":"https://api.github.com/repos/jdalsem/Elgg/branches{/branch}","tags_url":"https://api.github.com/repos/jdalsem/Elgg/tags","blobs_url":"https://api.github.com/repos/jdalsem/Elgg/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jdalsem/Elgg/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jdalsem/Elgg/git/refs{/sha}","trees_url":"https://api.github.com/repos/jdalsem/Elgg/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jdalsem/Elgg/statuses/{sha}","languages_url":"https://api.github.com/repos/jdalsem/Elgg/languages","stargazers_url":"https://api.github.com/repos/jdalsem/Elgg/stargazers","contributors_url":"https://api.github.com/repos/jdalsem/Elgg/contributors","subscribers_url":"https://api.github.com/repos/jdalsem/Elgg/subscribers","subscription_url":"https://api.github.com/repos/jdalsem/Elgg/subscription","commits_url":"https://api.github.com/repos/jdalsem/Elgg/commits{/sha}","git_commits_url":"https://api.github.com/repos/jdalsem/Elgg/git/commits{/sha}","comments_url":"https://api.github.com/repos/jdalsem/Elgg/comments{/number}","issue_comment_url":"https://api.github.com/repos/jdalsem/Elgg/issues/comments{/number}","contents_url":"https://api.github.com/repos/jdalsem/Elgg/contents/{+path}","compare_url":"https://api.github.com/repos/jdalsem/Elgg/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jdalsem/Elgg/merges","archive_url":"https://api.github.com/repos/jdalsem/Elgg/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jdalsem/Elgg/downloads","issues_url":"https://api.github.com/repos/jdalsem/Elgg/issues{/number}","pulls_url":"https://api.github.com/repos/jdalsem/Elgg/pulls{/number}","milestones_url":"https://api.github.com/repos/jdalsem/Elgg/milestones{/number}","notifications_url":"https://api.github.com/repos/jdalsem/Elgg/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jdalsem/Elgg/labels{/name}","releases_url":"https://api.github.com/repos/jdalsem/Elgg/releases{/id}","created_at":"2011-12-29T09:43:57Z","updated_at":"2014-06-24T10:31:40Z","pushed_at":"2015-07-02T13:26:24Z","git_url":"git://github.com/jdalsem/Elgg.git","ssh_url":"git@github.com:jdalsem/Elgg.git","clone_url":"https://github.com/jdalsem/Elgg.git","svn_url":"https://github.com/jdalsem/Elgg","homepage":"http://elgg.org","size":41840,"stargazers_count":1,"watchers_count":1,"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":1,"default_branch":"master"}},"base":{"label":"Elgg:master","ref":"master","sha":"45d1c2f16d732cedb4dc9ef0a679371438132d42","user":{"login":"Elgg","id":79167,"avatar_url":"https://avatars.githubusercontent.com/u/79167?v=3","gravatar_id":"","url":"https://api.github.com/users/Elgg","html_url":"https://github.com/Elgg","followers_url":"https://api.github.com/users/Elgg/followers","following_url":"https://api.github.com/users/Elgg/following{/other_user}","gists_url":"https://api.github.com/users/Elgg/gists{/gist_id}","starred_url":"https://api.github.com/users/Elgg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Elgg/subscriptions","organizations_url":"https://api.github.com/users/Elgg/orgs","repos_url":"https://api.github.com/users/Elgg/repos","events_url":"https://api.github.com/users/Elgg/events{/privacy}","received_events_url":"https://api.github.com/users/Elgg/received_events","type":"Organization","site_admin":false},"repo":{"id":299271,"name":"Elgg","full_name":"Elgg/Elgg","owner":{"login":"Elgg","id":79167,"avatar_url":"https://avatars.githubusercontent.com/u/79167?v=3","gravatar_id":"","url":"https://api.github.com/users/Elgg","html_url":"https://github.com/Elgg","followers_url":"https://api.github.com/users/Elgg/followers","following_url":"https://api.github.com/users/Elgg/following{/other_user}","gists_url":"https://api.github.com/users/Elgg/gists{/gist_id}","starred_url":"https://api.github.com/users/Elgg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Elgg/subscriptions","organizations_url":"https://api.github.com/users/Elgg/orgs","repos_url":"https://api.github.com/users/Elgg/repos","events_url":"https://api.github.com/users/Elgg/events{/privacy}","received_events_url":"https://api.github.com/users/Elgg/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Elgg/Elgg","description":"A social networking engine in PHP/MySQL","fork":false,"url":"https://api.github.com/repos/Elgg/Elgg","forks_url":"https://api.github.com/repos/Elgg/Elgg/forks","keys_url":"https://api.github.com/repos/Elgg/Elgg/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Elgg/Elgg/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Elgg/Elgg/teams","hooks_url":"https://api.github.com/repos/Elgg/Elgg/hooks","issue_events_url":"https://api.github.com/repos/Elgg/Elgg/issues/events{/number}","events_url":"https://api.github.com/repos/Elgg/Elgg/events","assignees_url":"https://api.github.com/repos/Elgg/Elgg/assignees{/user}","branches_url":"https://api.github.com/repos/Elgg/Elgg/branches{/branch}","tags_url":"https://api.github.com/repos/Elgg/Elgg/tags","blobs_url":"https://api.github.com/repos/Elgg/Elgg/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Elgg/Elgg/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Elgg/Elgg/git/refs{/sha}","trees_url":"https://api.github.com/repos/Elgg/Elgg/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Elgg/Elgg/statuses/{sha}","languages_url":"https://api.github.com/repos/Elgg/Elgg/languages","stargazers_url":"https://api.github.com/repos/Elgg/Elgg/stargazers","contributors_url":"https://api.github.com/repos/Elgg/Elgg/contributors","subscribers_url":"https://api.github.com/repos/Elgg/Elgg/subscribers","subscription_url":"https://api.github.com/repos/Elgg/Elgg/subscription","commits_url":"https://api.github.com/repos/Elgg/Elgg/commits{/sha}","git_commits_url":"https://api.github.com/repos/Elgg/Elgg/git/commits{/sha}","comments_url":"https://api.github.com/repos/Elgg/Elgg/comments{/number}","issue_comment_url":"https://api.github.com/repos/Elgg/Elgg/issues/comments{/number}","contents_url":"https://api.github.com/repos/Elgg/Elgg/contents/{+path}","compare_url":"https://api.github.com/repos/Elgg/Elgg/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Elgg/Elgg/merges","archive_url":"https://api.github.com/repos/Elgg/Elgg/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Elgg/Elgg/downloads","issues_url":"https://api.github.com/repos/Elgg/Elgg/issues{/number}","pulls_url":"https://api.github.com/repos/Elgg/Elgg/pulls{/number}","milestones_url":"https://api.github.com/repos/Elgg/Elgg/milestones{/number}","notifications_url":"https://api.github.com/repos/Elgg/Elgg/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Elgg/Elgg/labels{/name}","releases_url":"https://api.github.com/repos/Elgg/Elgg/releases{/id}","created_at":"2009-09-06T17:10:11Z","updated_at":"2015-06-30T16:49:58Z","pushed_at":"2015-07-02T15:11:13Z","git_url":"git://github.com/Elgg/Elgg.git","ssh_url":"git@github.com:Elgg/Elgg.git","clone_url":"https://github.com/Elgg/Elgg.git","svn_url":"https://github.com/Elgg/Elgg","homepage":"http://elgg.org","size":79139,"stargazers_count":746,"watchers_count":746,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":439,"mirror_url":null,"open_issues_count":749,"forks":439,"open_issues":749,"watchers":746,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/8654"},"html":{"href":"https://github.com/Elgg/Elgg/pull/8654"},"issue":{"href":"https://api.github.com/repos/Elgg/Elgg/issues/8654"},"comments":{"href":"https://api.github.com/repos/Elgg/Elgg/issues/8654/comments"},"review_comments":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/8654/comments"},"review_comment":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Elgg/Elgg/pulls/8654/commits"},"statuses":{"href":"https://api.github.com/repos/Elgg/Elgg/statuses/bfd3e27ab89730920b8b683907cf59abec12a890"}}}}