{"action":"created","issue":{"url":"https://api.github.com/repos/if712/php_first_blog/issues/3","repository_url":"https://api.github.com/repos/if712/php_first_blog","labels_url":"https://api.github.com/repos/if712/php_first_blog/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/if712/php_first_blog/issues/3/comments","events_url":"https://api.github.com/repos/if712/php_first_blog/issues/3/events","html_url":"https://github.com/if712/php_first_blog/issues/3","id":146198083,"number":3,"title":"Изменение глобального состояния","user":{"login":"Puppollo","id":7393039,"avatar_url":"https://avatars.githubusercontent.com/u/7393039?v=3","gravatar_id":"","url":"https://api.github.com/users/Puppollo","html_url":"https://github.com/Puppollo","followers_url":"https://api.github.com/users/Puppollo/followers","following_url":"https://api.github.com/users/Puppollo/following{/other_user}","gists_url":"https://api.github.com/users/Puppollo/gists{/gist_id}","starred_url":"https://api.github.com/users/Puppollo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Puppollo/subscriptions","organizations_url":"https://api.github.com/users/Puppollo/orgs","repos_url":"https://api.github.com/users/Puppollo/repos","events_url":"https://api.github.com/users/Puppollo/events{/privacy}","received_events_url":"https://api.github.com/users/Puppollo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-04-06T06:18:05Z","updated_at":"2016-04-06T06:18:20Z","closed_at":null,"body":"Хорошая функция должна принимать аргументы и возвращать значения в зависимости от аргументов и только от них, не изменяя глобальное состояние скрипта. \r\nфункция delete_user меняет глобальное состояние\r\n```\r\n    unset($_POST['delete']);\r\n    session_unset();\r\n    session_destroy();\r\n    header(\"Location: /src/public\");\r\n```"},"comment":{"url":"https://api.github.com/repos/if712/php_first_blog/issues/comments/206137257","html_url":"https://github.com/if712/php_first_blog/issues/3#issuecomment-206137257","issue_url":"https://api.github.com/repos/if712/php_first_blog/issues/3","id":206137257,"user":{"login":"Puppollo","id":7393039,"avatar_url":"https://avatars.githubusercontent.com/u/7393039?v=3","gravatar_id":"","url":"https://api.github.com/users/Puppollo","html_url":"https://github.com/Puppollo","followers_url":"https://api.github.com/users/Puppollo/followers","following_url":"https://api.github.com/users/Puppollo/following{/other_user}","gists_url":"https://api.github.com/users/Puppollo/gists{/gist_id}","starred_url":"https://api.github.com/users/Puppollo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Puppollo/subscriptions","organizations_url":"https://api.github.com/users/Puppollo/orgs","repos_url":"https://api.github.com/users/Puppollo/repos","events_url":"https://api.github.com/users/Puppollo/events{/privacy}","received_events_url":"https://api.github.com/users/Puppollo/received_events","type":"User","site_admin":false},"created_at":"2016-04-06T06:18:20Z","updated_at":"2016-04-06T06:18:20Z","body":"И не только delete_user 8)"}}