{"action":"created","comment":{"url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/comments/36085366","id":36085366,"diff_hunk":"@@ -2,13 +2,29 @@\n from django.contrib.auth.models import User\n from tastypie.utils.timezone import now\n \n+class Group(models.Model):\n+  users = models.ManyToManyField(User, related_name='users')","path":"items/models.py","position":5,"original_position":5,"commit_id":"8192216bc5a715443a45041c9712a8260adb7c4e","original_commit_id":"8192216bc5a715443a45041c9712a8260adb7c4e","user":{"login":"alekseyC64","id":4508216,"avatar_url":"https://avatars.githubusercontent.com/u/4508216?v=3","gravatar_id":"","url":"https://api.github.com/users/alekseyC64","html_url":"https://github.com/alekseyC64","followers_url":"https://api.github.com/users/alekseyC64/followers","following_url":"https://api.github.com/users/alekseyC64/following{/other_user}","gists_url":"https://api.github.com/users/alekseyC64/gists{/gist_id}","starred_url":"https://api.github.com/users/alekseyC64/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alekseyC64/subscriptions","organizations_url":"https://api.github.com/users/alekseyC64/orgs","repos_url":"https://api.github.com/users/alekseyC64/repos","events_url":"https://api.github.com/users/alekseyC64/events{/privacy}","received_events_url":"https://api.github.com/users/alekseyC64/received_events","type":"User","site_admin":false},"body":"`related_name` is wrong here. It could be `groups` or something. Basically it's better to not use related_name since you already have access to such attributes through django - https://docs.djangoproject.com/en/1.8/topics/db/queries/#related-objects","created_at":"2015-08-03T13:39:25Z","updated_at":"2015-08-03T13:39:25Z","html_url":"https://github.com/NikitaSedyx/todo-dj/pull/5#discussion_r36085366","pull_request_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/comments/36085366"},"html":{"href":"https://github.com/NikitaSedyx/todo-dj/pull/5#discussion_r36085366"},"pull_request":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5","id":41227037,"html_url":"https://github.com/NikitaSedyx/todo-dj/pull/5","diff_url":"https://github.com/NikitaSedyx/todo-dj/pull/5.diff","patch_url":"https://github.com/NikitaSedyx/todo-dj/pull/5.patch","issue_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/5","number":5,"state":"open","locked":false,"title":"Groups1.0","user":{"login":"NikitaSedyx","id":12440608,"avatar_url":"https://avatars.githubusercontent.com/u/12440608?v=3","gravatar_id":"","url":"https://api.github.com/users/NikitaSedyx","html_url":"https://github.com/NikitaSedyx","followers_url":"https://api.github.com/users/NikitaSedyx/followers","following_url":"https://api.github.com/users/NikitaSedyx/following{/other_user}","gists_url":"https://api.github.com/users/NikitaSedyx/gists{/gist_id}","starred_url":"https://api.github.com/users/NikitaSedyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NikitaSedyx/subscriptions","organizations_url":"https://api.github.com/users/NikitaSedyx/orgs","repos_url":"https://api.github.com/users/NikitaSedyx/repos","events_url":"https://api.github.com/users/NikitaSedyx/events{/privacy}","received_events_url":"https://api.github.com/users/NikitaSedyx/received_events","type":"User","site_admin":false},"body":"Was changed settings for working with postgresql, added group model, resource and authorization, changed item model, resource and authorization","created_at":"2015-07-30T12:16:10Z","updated_at":"2015-08-03T13:39:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4f6241c31a528e87d1fd2bf0022503cf2d455655","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5/commits","review_comments_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5/comments","review_comment_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/comments{/number}","comments_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/5/comments","statuses_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/statuses/8192216bc5a715443a45041c9712a8260adb7c4e","head":{"label":"NikitaSedyx:groups1.0","ref":"groups1.0","sha":"8192216bc5a715443a45041c9712a8260adb7c4e","user":{"login":"NikitaSedyx","id":12440608,"avatar_url":"https://avatars.githubusercontent.com/u/12440608?v=3","gravatar_id":"","url":"https://api.github.com/users/NikitaSedyx","html_url":"https://github.com/NikitaSedyx","followers_url":"https://api.github.com/users/NikitaSedyx/followers","following_url":"https://api.github.com/users/NikitaSedyx/following{/other_user}","gists_url":"https://api.github.com/users/NikitaSedyx/gists{/gist_id}","starred_url":"https://api.github.com/users/NikitaSedyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NikitaSedyx/subscriptions","organizations_url":"https://api.github.com/users/NikitaSedyx/orgs","repos_url":"https://api.github.com/users/NikitaSedyx/repos","events_url":"https://api.github.com/users/NikitaSedyx/events{/privacy}","received_events_url":"https://api.github.com/users/NikitaSedyx/received_events","type":"User","site_admin":false},"repo":{"id":38311530,"name":"todo-dj","full_name":"NikitaSedyx/todo-dj","owner":{"login":"NikitaSedyx","id":12440608,"avatar_url":"https://avatars.githubusercontent.com/u/12440608?v=3","gravatar_id":"","url":"https://api.github.com/users/NikitaSedyx","html_url":"https://github.com/NikitaSedyx","followers_url":"https://api.github.com/users/NikitaSedyx/followers","following_url":"https://api.github.com/users/NikitaSedyx/following{/other_user}","gists_url":"https://api.github.com/users/NikitaSedyx/gists{/gist_id}","starred_url":"https://api.github.com/users/NikitaSedyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NikitaSedyx/subscriptions","organizations_url":"https://api.github.com/users/NikitaSedyx/orgs","repos_url":"https://api.github.com/users/NikitaSedyx/repos","events_url":"https://api.github.com/users/NikitaSedyx/events{/privacy}","received_events_url":"https://api.github.com/users/NikitaSedyx/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/NikitaSedyx/todo-dj","description":"","fork":false,"url":"https://api.github.com/repos/NikitaSedyx/todo-dj","forks_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/forks","keys_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/teams","hooks_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/hooks","issue_events_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/events{/number}","events_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/events","assignees_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/assignees{/user}","branches_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/branches{/branch}","tags_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/tags","blobs_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/refs{/sha}","trees_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/statuses/{sha}","languages_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/languages","stargazers_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/stargazers","contributors_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/contributors","subscribers_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/subscribers","subscription_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/subscription","commits_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/commits{/sha}","git_commits_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/commits{/sha}","comments_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/comments{/number}","issue_comment_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/comments{/number}","contents_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/contents/{+path}","compare_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/merges","archive_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/downloads","issues_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues{/number}","pulls_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls{/number}","milestones_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/milestones{/number}","notifications_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/labels{/name}","releases_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/releases{/id}","created_at":"2015-06-30T13:43:48Z","updated_at":"2015-07-07T09:18:27Z","pushed_at":"2015-07-31T06:35:47Z","git_url":"git://github.com/NikitaSedyx/todo-dj.git","ssh_url":"git@github.com:NikitaSedyx/todo-dj.git","clone_url":"https://github.com/NikitaSedyx/todo-dj.git","svn_url":"https://github.com/NikitaSedyx/todo-dj","homepage":null,"size":224,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"NikitaSedyx:master","ref":"master","sha":"db9389cde5f06412325febf9d1d9f56e5f561f73","user":{"login":"NikitaSedyx","id":12440608,"avatar_url":"https://avatars.githubusercontent.com/u/12440608?v=3","gravatar_id":"","url":"https://api.github.com/users/NikitaSedyx","html_url":"https://github.com/NikitaSedyx","followers_url":"https://api.github.com/users/NikitaSedyx/followers","following_url":"https://api.github.com/users/NikitaSedyx/following{/other_user}","gists_url":"https://api.github.com/users/NikitaSedyx/gists{/gist_id}","starred_url":"https://api.github.com/users/NikitaSedyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NikitaSedyx/subscriptions","organizations_url":"https://api.github.com/users/NikitaSedyx/orgs","repos_url":"https://api.github.com/users/NikitaSedyx/repos","events_url":"https://api.github.com/users/NikitaSedyx/events{/privacy}","received_events_url":"https://api.github.com/users/NikitaSedyx/received_events","type":"User","site_admin":false},"repo":{"id":38311530,"name":"todo-dj","full_name":"NikitaSedyx/todo-dj","owner":{"login":"NikitaSedyx","id":12440608,"avatar_url":"https://avatars.githubusercontent.com/u/12440608?v=3","gravatar_id":"","url":"https://api.github.com/users/NikitaSedyx","html_url":"https://github.com/NikitaSedyx","followers_url":"https://api.github.com/users/NikitaSedyx/followers","following_url":"https://api.github.com/users/NikitaSedyx/following{/other_user}","gists_url":"https://api.github.com/users/NikitaSedyx/gists{/gist_id}","starred_url":"https://api.github.com/users/NikitaSedyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NikitaSedyx/subscriptions","organizations_url":"https://api.github.com/users/NikitaSedyx/orgs","repos_url":"https://api.github.com/users/NikitaSedyx/repos","events_url":"https://api.github.com/users/NikitaSedyx/events{/privacy}","received_events_url":"https://api.github.com/users/NikitaSedyx/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/NikitaSedyx/todo-dj","description":"","fork":false,"url":"https://api.github.com/repos/NikitaSedyx/todo-dj","forks_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/forks","keys_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/teams","hooks_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/hooks","issue_events_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/events{/number}","events_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/events","assignees_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/assignees{/user}","branches_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/branches{/branch}","tags_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/tags","blobs_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/refs{/sha}","trees_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/statuses/{sha}","languages_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/languages","stargazers_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/stargazers","contributors_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/contributors","subscribers_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/subscribers","subscription_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/subscription","commits_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/commits{/sha}","git_commits_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/git/commits{/sha}","comments_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/comments{/number}","issue_comment_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/comments{/number}","contents_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/contents/{+path}","compare_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/merges","archive_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/downloads","issues_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues{/number}","pulls_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls{/number}","milestones_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/milestones{/number}","notifications_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/labels{/name}","releases_url":"https://api.github.com/repos/NikitaSedyx/todo-dj/releases{/id}","created_at":"2015-06-30T13:43:48Z","updated_at":"2015-07-07T09:18:27Z","pushed_at":"2015-07-31T06:35:47Z","git_url":"git://github.com/NikitaSedyx/todo-dj.git","ssh_url":"git@github.com:NikitaSedyx/todo-dj.git","clone_url":"https://github.com/NikitaSedyx/todo-dj.git","svn_url":"https://github.com/NikitaSedyx/todo-dj","homepage":null,"size":224,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5"},"html":{"href":"https://github.com/NikitaSedyx/todo-dj/pull/5"},"issue":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/5"},"comments":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/NikitaSedyx/todo-dj/statuses/8192216bc5a715443a45041c9712a8260adb7c4e"}}}}