{"action":"created","comment":{"url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/comments/25811209","id":25811209,"diff_hunk":"@@ -2643,19 +2609,18 @@ public function setMenuTitle($value) {\n \t}\n \t\n \t/**\n-\t * A flag provides the user with additional data about the current page status,\n-\t * for example a \"removed from draft\" status. Each page can have more than one status flag.\n-\t * Returns a map of a unique key to a (localized) title for the flag.\n-\t * The unique key can be reused as a CSS class.\n-\t * Use the 'updateStatusFlags' extension point to customize the flags.\n+\t * A flag provides the user with additional data about the current page status, for example a \"removed from draft\"\n+\t * status. Each page can have more than one status flag. Returns a map of a unique key to a (localized) title for\n+\t * the flag. The unique key can be reused as a CSS class. Use the 'updateStatusFlags' extension point to customize\n+\t * the flags.\n \t * \n \t * Example (simple): \n-\t * \"deletedonlive\" => \"Deleted\"\n+\t *   \"deletedonlive\" => \"Deleted\"\n \t * \n \t * Example (with optional title attribute): \n-\t * \"deletedonlive\" => array('text' => \"Deleted\", 'title' => 'This page has been deleted')\n+\t *   \"deletedonlive\" => array('text' => \"Deleted\", 'title' => 'This page has been deleted')\n \t *\n-\t * @param Boolean $cached\n+\t * @param bool $cached Whether to serve the fields from cache; false regenerate them","path":"code/model/SiteTree.php","position":1140,"original_position":1140,"commit_id":"36cad8c9e1d7545bce503b6da68b376427d5f6d4","original_commit_id":"36cad8c9e1d7545bce503b6da68b376427d5f6d4","user":{"login":"assertchris","id":200609,"avatar_url":"https://avatars.githubusercontent.com/u/200609?v=3","gravatar_id":"","url":"https://api.github.com/users/assertchris","html_url":"https://github.com/assertchris","followers_url":"https://api.github.com/users/assertchris/followers","following_url":"https://api.github.com/users/assertchris/following{/other_user}","gists_url":"https://api.github.com/users/assertchris/gists{/gist_id}","starred_url":"https://api.github.com/users/assertchris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/assertchris/subscriptions","organizations_url":"https://api.github.com/users/assertchris/orgs","repos_url":"https://api.github.com/users/assertchris/repos","events_url":"https://api.github.com/users/assertchris/events{/privacy}","received_events_url":"https://api.github.com/users/assertchris/received_events","type":"User","site_admin":false},"body":"> getStatusFlags is getStatusFlags(true) not getStatusFlags(null)\r\n\r\nThat would only be true if `true == null` which is not the case. Where it is called; `getStatusFlags()` is `getStatusFlags(null)`. The engine wires the default values up inside the function. I guess that's semantics though. \r\n\r\nThe important thing is that [static analysis] engines view nullable type hints differently to nullable type hints. Could you give `null` as a value to that parameter? Then `null` is an allowed type. Whether or not it will be given a default value (inside the function) or will be coerced or whatever. The type hints (in this case the type annotations) tell a static analyser what types are allowed, not what they will become. That is why `null` should be hinted/annotated for all PHP parameters with default values. ","created_at":"2015-03-04T20:34:45Z","updated_at":"2015-03-04T20:34:45Z","html_url":"https://github.com/silverstripe/silverstripe-cms/pull/1140#discussion_r25811209","pull_request_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140","_links":{"self":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/comments/25811209"},"html":{"href":"https://github.com/silverstripe/silverstripe-cms/pull/1140#discussion_r25811209"},"pull_request":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140"}}},"pull_request":{"url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140","id":25264979,"html_url":"https://github.com/silverstripe/silverstripe-cms/pull/1140","diff_url":"https://github.com/silverstripe/silverstripe-cms/pull/1140.diff","patch_url":"https://github.com/silverstripe/silverstripe-cms/pull/1140.patch","issue_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/1140","number":1140,"state":"open","locked":false,"title":"PHPDoc improvements for SiteTree and SiteTreeLinkTracking","user":{"login":"nikrolls","id":2626677,"avatar_url":"https://avatars.githubusercontent.com/u/2626677?v=3","gravatar_id":"","url":"https://api.github.com/users/nikrolls","html_url":"https://github.com/nikrolls","followers_url":"https://api.github.com/users/nikrolls/followers","following_url":"https://api.github.com/users/nikrolls/following{/other_user}","gists_url":"https://api.github.com/users/nikrolls/gists{/gist_id}","starred_url":"https://api.github.com/users/nikrolls/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikrolls/subscriptions","organizations_url":"https://api.github.com/users/nikrolls/orgs","repos_url":"https://api.github.com/users/nikrolls/repos","events_url":"https://api.github.com/users/nikrolls/events{/privacy}","received_events_url":"https://api.github.com/users/nikrolls/received_events","type":"User","site_admin":false},"body":"- Removed @param/@method references to fields from extensions\r\n- Added @mixin references to extensions (supported by PHPStorm, should also be by Netbeans)\r\n- Fixed incorrect PHPDoc @params and @returns\r\n- Fixed wrapping width on many docblocks\r\n- Added and/or improved method documentation when missing or confusing\r\n- General tweaks and fixes to match latest standards and IDE capabilities\r\n- Fixed typos as found\r\n\r\nFor the Framework counterpart see https://github.com/silverstripe/silverstripe-framework/pull/3698","created_at":"2014-12-01T12:31:28Z","updated_at":"2015-03-04T20:34:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cc244a8af523ab4d7e6eb771c98c3daa9278b764","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140/commits","review_comments_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140/comments","review_comment_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/comments{/number}","comments_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/1140/comments","statuses_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/statuses/36cad8c9e1d7545bce503b6da68b376427d5f6d4","head":{"label":"InfinityIo:sitetree-docblock-improvements","ref":"sitetree-docblock-improvements","sha":"36cad8c9e1d7545bce503b6da68b376427d5f6d4","user":{"login":"InfinityIo","id":6915424,"avatar_url":"https://avatars.githubusercontent.com/u/6915424?v=3","gravatar_id":"","url":"https://api.github.com/users/InfinityIo","html_url":"https://github.com/InfinityIo","followers_url":"https://api.github.com/users/InfinityIo/followers","following_url":"https://api.github.com/users/InfinityIo/following{/other_user}","gists_url":"https://api.github.com/users/InfinityIo/gists{/gist_id}","starred_url":"https://api.github.com/users/InfinityIo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/InfinityIo/subscriptions","organizations_url":"https://api.github.com/users/InfinityIo/orgs","repos_url":"https://api.github.com/users/InfinityIo/repos","events_url":"https://api.github.com/users/InfinityIo/events{/privacy}","received_events_url":"https://api.github.com/users/InfinityIo/received_events","type":"Organization","site_admin":false},"repo":{"id":23562927,"name":"silverstripe-cms","full_name":"InfinityIo/silverstripe-cms","owner":{"login":"InfinityIo","id":6915424,"avatar_url":"https://avatars.githubusercontent.com/u/6915424?v=3","gravatar_id":"","url":"https://api.github.com/users/InfinityIo","html_url":"https://github.com/InfinityIo","followers_url":"https://api.github.com/users/InfinityIo/followers","following_url":"https://api.github.com/users/InfinityIo/following{/other_user}","gists_url":"https://api.github.com/users/InfinityIo/gists{/gist_id}","starred_url":"https://api.github.com/users/InfinityIo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/InfinityIo/subscriptions","organizations_url":"https://api.github.com/users/InfinityIo/orgs","repos_url":"https://api.github.com/users/InfinityIo/repos","events_url":"https://api.github.com/users/InfinityIo/events{/privacy}","received_events_url":"https://api.github.com/users/InfinityIo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/InfinityIo/silverstripe-cms","description":"SilverStripe CMS - this is a module for SilverStripe Framework rather than a standalone app. Use https://github.com/silverstripe/silverstripe-installer/ to set this up.","fork":true,"url":"https://api.github.com/repos/InfinityIo/silverstripe-cms","forks_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/forks","keys_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/teams","hooks_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/hooks","issue_events_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/issues/events{/number}","events_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/events","assignees_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/assignees{/user}","branches_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/branches{/branch}","tags_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/tags","blobs_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/git/refs{/sha}","trees_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/statuses/{sha}","languages_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/languages","stargazers_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/stargazers","contributors_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/contributors","subscribers_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/subscribers","subscription_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/subscription","commits_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/commits{/sha}","git_commits_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/git/commits{/sha}","comments_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/comments{/number}","issue_comment_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/issues/comments{/number}","contents_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/contents/{+path}","compare_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/merges","archive_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/downloads","issues_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/issues{/number}","pulls_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/pulls{/number}","milestones_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/milestones{/number}","notifications_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/labels{/name}","releases_url":"https://api.github.com/repos/InfinityIo/silverstripe-cms/releases{/id}","created_at":"2014-09-02T02:56:07Z","updated_at":"2014-08-29T10:29:02Z","pushed_at":"2014-12-01T12:28:30Z","git_url":"git://github.com/InfinityIo/silverstripe-cms.git","ssh_url":"git@github.com:InfinityIo/silverstripe-cms.git","clone_url":"https://github.com/InfinityIo/silverstripe-cms.git","svn_url":"https://github.com/InfinityIo/silverstripe-cms","homepage":"http://silverstripe.org/","size":15700,"stargazers_count":0,"watchers_count":0,"language":null,"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":"3.1"}},"base":{"label":"silverstripe:3.1","ref":"3.1","sha":"708e70624c65e146abce2a88858d52b12653fa53","user":{"login":"silverstripe","id":379348,"avatar_url":"https://avatars.githubusercontent.com/u/379348?v=3","gravatar_id":"","url":"https://api.github.com/users/silverstripe","html_url":"https://github.com/silverstripe","followers_url":"https://api.github.com/users/silverstripe/followers","following_url":"https://api.github.com/users/silverstripe/following{/other_user}","gists_url":"https://api.github.com/users/silverstripe/gists{/gist_id}","starred_url":"https://api.github.com/users/silverstripe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/silverstripe/subscriptions","organizations_url":"https://api.github.com/users/silverstripe/orgs","repos_url":"https://api.github.com/users/silverstripe/repos","events_url":"https://api.github.com/users/silverstripe/events{/privacy}","received_events_url":"https://api.github.com/users/silverstripe/received_events","type":"Organization","site_admin":false},"repo":{"id":1319183,"name":"silverstripe-cms","full_name":"silverstripe/silverstripe-cms","owner":{"login":"silverstripe","id":379348,"avatar_url":"https://avatars.githubusercontent.com/u/379348?v=3","gravatar_id":"","url":"https://api.github.com/users/silverstripe","html_url":"https://github.com/silverstripe","followers_url":"https://api.github.com/users/silverstripe/followers","following_url":"https://api.github.com/users/silverstripe/following{/other_user}","gists_url":"https://api.github.com/users/silverstripe/gists{/gist_id}","starred_url":"https://api.github.com/users/silverstripe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/silverstripe/subscriptions","organizations_url":"https://api.github.com/users/silverstripe/orgs","repos_url":"https://api.github.com/users/silverstripe/repos","events_url":"https://api.github.com/users/silverstripe/events{/privacy}","received_events_url":"https://api.github.com/users/silverstripe/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/silverstripe/silverstripe-cms","description":"SilverStripe CMS - this is a module for SilverStripe Framework rather than a standalone app. Use https://github.com/silverstripe/silverstripe-installer/ to set this up.","fork":false,"url":"https://api.github.com/repos/silverstripe/silverstripe-cms","forks_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/forks","keys_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/teams","hooks_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/hooks","issue_events_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/events{/number}","events_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/events","assignees_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/assignees{/user}","branches_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/branches{/branch}","tags_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/tags","blobs_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/git/refs{/sha}","trees_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/statuses/{sha}","languages_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/languages","stargazers_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/stargazers","contributors_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/contributors","subscribers_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/subscribers","subscription_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/subscription","commits_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/commits{/sha}","git_commits_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/git/commits{/sha}","comments_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/comments{/number}","issue_comment_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/comments{/number}","contents_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/contents/{+path}","compare_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/merges","archive_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/downloads","issues_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues{/number}","pulls_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls{/number}","milestones_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/milestones{/number}","notifications_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/labels{/name}","releases_url":"https://api.github.com/repos/silverstripe/silverstripe-cms/releases{/id}","created_at":"2011-02-02T04:01:36Z","updated_at":"2015-03-03T18:33:08Z","pushed_at":"2015-02-23T22:45:21Z","git_url":"git://github.com/silverstripe/silverstripe-cms.git","ssh_url":"git@github.com:silverstripe/silverstripe-cms.git","clone_url":"https://github.com/silverstripe/silverstripe-cms.git","svn_url":"https://github.com/silverstripe/silverstripe-cms","homepage":"http://silverstripe.org/","size":18189,"stargazers_count":329,"watchers_count":329,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":234,"mirror_url":null,"open_issues_count":300,"forks":234,"open_issues":300,"watchers":329,"default_branch":"3.1"}},"_links":{"self":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140"},"html":{"href":"https://github.com/silverstripe/silverstripe-cms/pull/1140"},"issue":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/1140"},"comments":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/issues/1140/comments"},"review_comments":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140/comments"},"review_comment":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/pulls/1140/commits"},"statuses":{"href":"https://api.github.com/repos/silverstripe/silverstripe-cms/statuses/36cad8c9e1d7545bce503b6da68b376427d5f6d4"}}}}