{"action":"created","comment":{"url":"https://api.github.com/repos/theforeman/foreman/pulls/comments/30223171","id":30223171,"diff_hunk":"@@ -2,7 +2,7 @@ class Permission < ActiveRecord::Base\n   attr_accessible :name, :resource_type\n \n   validates_lengths_from_database\n-  validates :name, :presence => true, :uniqueness => { :scope => :resource_type }\n+  validates :name, :presence => true","path":"app/models/permission.rb","position":5,"original_position":5,"commit_id":"1a9fe5bf46e54f229d90b55694d2032efb588f1c","original_commit_id":"1a9fe5bf46e54f229d90b55694d2032efb588f1c","user":{"login":"isratrade","id":505394,"avatar_url":"https://avatars.githubusercontent.com/u/505394?v=3","gravatar_id":"","url":"https://api.github.com/users/isratrade","html_url":"https://github.com/isratrade","followers_url":"https://api.github.com/users/isratrade/followers","following_url":"https://api.github.com/users/isratrade/following{/other_user}","gists_url":"https://api.github.com/users/isratrade/gists{/gist_id}","starred_url":"https://api.github.com/users/isratrade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isratrade/subscriptions","organizations_url":"https://api.github.com/users/isratrade/orgs","repos_url":"https://api.github.com/users/isratrade/repos","events_url":"https://api.github.com/users/isratrade/events{/privacy}","received_events_url":"https://api.github.com/users/isratrade/received_events","type":"User","site_admin":false},"body":"re-committed with this change to remove uniqueness by scope.","created_at":"2015-05-13T11:52:46Z","updated_at":"2015-05-13T11:52:46Z","html_url":"https://github.com/theforeman/foreman/pull/2377#discussion_r30223171","pull_request_url":"https://api.github.com/repos/theforeman/foreman/pulls/2377","_links":{"self":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/comments/30223171"},"html":{"href":"https://github.com/theforeman/foreman/pull/2377#discussion_r30223171"},"pull_request":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/2377"}}},"pull_request":{"url":"https://api.github.com/repos/theforeman/foreman/pulls/2377","id":35302467,"html_url":"https://github.com/theforeman/foreman/pull/2377","diff_url":"https://github.com/theforeman/foreman/pull/2377.diff","patch_url":"https://github.com/theforeman/foreman/pull/2377.patch","issue_url":"https://api.github.com/repos/theforeman/foreman/issues/2377","number":2377,"state":"open","locked":false,"title":"fixes #10492 - validate permission name should be unique and not scoped by resource_type","user":{"login":"isratrade","id":505394,"avatar_url":"https://avatars.githubusercontent.com/u/505394?v=3","gravatar_id":"","url":"https://api.github.com/users/isratrade","html_url":"https://github.com/isratrade","followers_url":"https://api.github.com/users/isratrade/followers","following_url":"https://api.github.com/users/isratrade/following{/other_user}","gists_url":"https://api.github.com/users/isratrade/gists{/gist_id}","starred_url":"https://api.github.com/users/isratrade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isratrade/subscriptions","organizations_url":"https://api.github.com/users/isratrade/orgs","repos_url":"https://api.github.com/users/isratrade/repos","events_url":"https://api.github.com/users/isratrade/events{/privacy}","received_events_url":"https://api.github.com/users/isratrade/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-05-13T08:03:02Z","updated_at":"2015-05-13T11:52:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a60adf68a7fa3282c6f2425fb112ffaef3940260","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/theforeman/foreman/pulls/2377/commits","review_comments_url":"https://api.github.com/repos/theforeman/foreman/pulls/2377/comments","review_comment_url":"https://api.github.com/repos/theforeman/foreman/pulls/comments{/number}","comments_url":"https://api.github.com/repos/theforeman/foreman/issues/2377/comments","statuses_url":"https://api.github.com/repos/theforeman/foreman/statuses/1a9fe5bf46e54f229d90b55694d2032efb588f1c","head":{"label":"isratrade:10492","ref":"10492","sha":"1a9fe5bf46e54f229d90b55694d2032efb588f1c","user":{"login":"isratrade","id":505394,"avatar_url":"https://avatars.githubusercontent.com/u/505394?v=3","gravatar_id":"","url":"https://api.github.com/users/isratrade","html_url":"https://github.com/isratrade","followers_url":"https://api.github.com/users/isratrade/followers","following_url":"https://api.github.com/users/isratrade/following{/other_user}","gists_url":"https://api.github.com/users/isratrade/gists{/gist_id}","starred_url":"https://api.github.com/users/isratrade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isratrade/subscriptions","organizations_url":"https://api.github.com/users/isratrade/orgs","repos_url":"https://api.github.com/users/isratrade/repos","events_url":"https://api.github.com/users/isratrade/events{/privacy}","received_events_url":"https://api.github.com/users/isratrade/received_events","type":"User","site_admin":false},"repo":{"id":5506478,"name":"foreman","full_name":"isratrade/foreman","owner":{"login":"isratrade","id":505394,"avatar_url":"https://avatars.githubusercontent.com/u/505394?v=3","gravatar_id":"","url":"https://api.github.com/users/isratrade","html_url":"https://github.com/isratrade","followers_url":"https://api.github.com/users/isratrade/followers","following_url":"https://api.github.com/users/isratrade/following{/other_user}","gists_url":"https://api.github.com/users/isratrade/gists{/gist_id}","starred_url":"https://api.github.com/users/isratrade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isratrade/subscriptions","organizations_url":"https://api.github.com/users/isratrade/orgs","repos_url":"https://api.github.com/users/isratrade/repos","events_url":"https://api.github.com/users/isratrade/events{/privacy}","received_events_url":"https://api.github.com/users/isratrade/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/isratrade/foreman","description":"an application that automates the lifecycle of servers ","fork":true,"url":"https://api.github.com/repos/isratrade/foreman","forks_url":"https://api.github.com/repos/isratrade/foreman/forks","keys_url":"https://api.github.com/repos/isratrade/foreman/keys{/key_id}","collaborators_url":"https://api.github.com/repos/isratrade/foreman/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/isratrade/foreman/teams","hooks_url":"https://api.github.com/repos/isratrade/foreman/hooks","issue_events_url":"https://api.github.com/repos/isratrade/foreman/issues/events{/number}","events_url":"https://api.github.com/repos/isratrade/foreman/events","assignees_url":"https://api.github.com/repos/isratrade/foreman/assignees{/user}","branches_url":"https://api.github.com/repos/isratrade/foreman/branches{/branch}","tags_url":"https://api.github.com/repos/isratrade/foreman/tags","blobs_url":"https://api.github.com/repos/isratrade/foreman/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/isratrade/foreman/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/isratrade/foreman/git/refs{/sha}","trees_url":"https://api.github.com/repos/isratrade/foreman/git/trees{/sha}","statuses_url":"https://api.github.com/repos/isratrade/foreman/statuses/{sha}","languages_url":"https://api.github.com/repos/isratrade/foreman/languages","stargazers_url":"https://api.github.com/repos/isratrade/foreman/stargazers","contributors_url":"https://api.github.com/repos/isratrade/foreman/contributors","subscribers_url":"https://api.github.com/repos/isratrade/foreman/subscribers","subscription_url":"https://api.github.com/repos/isratrade/foreman/subscription","commits_url":"https://api.github.com/repos/isratrade/foreman/commits{/sha}","git_commits_url":"https://api.github.com/repos/isratrade/foreman/git/commits{/sha}","comments_url":"https://api.github.com/repos/isratrade/foreman/comments{/number}","issue_comment_url":"https://api.github.com/repos/isratrade/foreman/issues/comments{/number}","contents_url":"https://api.github.com/repos/isratrade/foreman/contents/{+path}","compare_url":"https://api.github.com/repos/isratrade/foreman/compare/{base}...{head}","merges_url":"https://api.github.com/repos/isratrade/foreman/merges","archive_url":"https://api.github.com/repos/isratrade/foreman/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/isratrade/foreman/downloads","issues_url":"https://api.github.com/repos/isratrade/foreman/issues{/number}","pulls_url":"https://api.github.com/repos/isratrade/foreman/pulls{/number}","milestones_url":"https://api.github.com/repos/isratrade/foreman/milestones{/number}","notifications_url":"https://api.github.com/repos/isratrade/foreman/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/isratrade/foreman/labels{/name}","releases_url":"https://api.github.com/repos/isratrade/foreman/releases{/id}","created_at":"2012-08-22T08:06:55Z","updated_at":"2014-06-25T09:16:11Z","pushed_at":"2015-05-13T11:51:07Z","git_url":"git://github.com/isratrade/foreman.git","ssh_url":"git@github.com:isratrade/foreman.git","clone_url":"https://github.com/isratrade/foreman.git","svn_url":"https://github.com/isratrade/foreman","homepage":"http://theforeman.org","size":32860,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"develop"}},"base":{"label":"theforeman:develop","ref":"develop","sha":"60fdfb3851cad0ff347788c1f796d709693a8f27","user":{"login":"theforeman","id":1439844,"avatar_url":"https://avatars.githubusercontent.com/u/1439844?v=3","gravatar_id":"","url":"https://api.github.com/users/theforeman","html_url":"https://github.com/theforeman","followers_url":"https://api.github.com/users/theforeman/followers","following_url":"https://api.github.com/users/theforeman/following{/other_user}","gists_url":"https://api.github.com/users/theforeman/gists{/gist_id}","starred_url":"https://api.github.com/users/theforeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theforeman/subscriptions","organizations_url":"https://api.github.com/users/theforeman/orgs","repos_url":"https://api.github.com/users/theforeman/repos","events_url":"https://api.github.com/users/theforeman/events{/privacy}","received_events_url":"https://api.github.com/users/theforeman/received_events","type":"Organization","site_admin":false},"repo":{"id":258750,"name":"foreman","full_name":"theforeman/foreman","owner":{"login":"theforeman","id":1439844,"avatar_url":"https://avatars.githubusercontent.com/u/1439844?v=3","gravatar_id":"","url":"https://api.github.com/users/theforeman","html_url":"https://github.com/theforeman","followers_url":"https://api.github.com/users/theforeman/followers","following_url":"https://api.github.com/users/theforeman/following{/other_user}","gists_url":"https://api.github.com/users/theforeman/gists{/gist_id}","starred_url":"https://api.github.com/users/theforeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theforeman/subscriptions","organizations_url":"https://api.github.com/users/theforeman/orgs","repos_url":"https://api.github.com/users/theforeman/repos","events_url":"https://api.github.com/users/theforeman/events{/privacy}","received_events_url":"https://api.github.com/users/theforeman/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/theforeman/foreman","description":"an application that automates the lifecycle of servers ","fork":false,"url":"https://api.github.com/repos/theforeman/foreman","forks_url":"https://api.github.com/repos/theforeman/foreman/forks","keys_url":"https://api.github.com/repos/theforeman/foreman/keys{/key_id}","collaborators_url":"https://api.github.com/repos/theforeman/foreman/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/theforeman/foreman/teams","hooks_url":"https://api.github.com/repos/theforeman/foreman/hooks","issue_events_url":"https://api.github.com/repos/theforeman/foreman/issues/events{/number}","events_url":"https://api.github.com/repos/theforeman/foreman/events","assignees_url":"https://api.github.com/repos/theforeman/foreman/assignees{/user}","branches_url":"https://api.github.com/repos/theforeman/foreman/branches{/branch}","tags_url":"https://api.github.com/repos/theforeman/foreman/tags","blobs_url":"https://api.github.com/repos/theforeman/foreman/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/theforeman/foreman/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/theforeman/foreman/git/refs{/sha}","trees_url":"https://api.github.com/repos/theforeman/foreman/git/trees{/sha}","statuses_url":"https://api.github.com/repos/theforeman/foreman/statuses/{sha}","languages_url":"https://api.github.com/repos/theforeman/foreman/languages","stargazers_url":"https://api.github.com/repos/theforeman/foreman/stargazers","contributors_url":"https://api.github.com/repos/theforeman/foreman/contributors","subscribers_url":"https://api.github.com/repos/theforeman/foreman/subscribers","subscription_url":"https://api.github.com/repos/theforeman/foreman/subscription","commits_url":"https://api.github.com/repos/theforeman/foreman/commits{/sha}","git_commits_url":"https://api.github.com/repos/theforeman/foreman/git/commits{/sha}","comments_url":"https://api.github.com/repos/theforeman/foreman/comments{/number}","issue_comment_url":"https://api.github.com/repos/theforeman/foreman/issues/comments{/number}","contents_url":"https://api.github.com/repos/theforeman/foreman/contents/{+path}","compare_url":"https://api.github.com/repos/theforeman/foreman/compare/{base}...{head}","merges_url":"https://api.github.com/repos/theforeman/foreman/merges","archive_url":"https://api.github.com/repos/theforeman/foreman/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/theforeman/foreman/downloads","issues_url":"https://api.github.com/repos/theforeman/foreman/issues{/number}","pulls_url":"https://api.github.com/repos/theforeman/foreman/pulls{/number}","milestones_url":"https://api.github.com/repos/theforeman/foreman/milestones{/number}","notifications_url":"https://api.github.com/repos/theforeman/foreman/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/theforeman/foreman/labels{/name}","releases_url":"https://api.github.com/repos/theforeman/foreman/releases{/id}","created_at":"2009-07-23T15:07:00Z","updated_at":"2015-05-11T06:52:48Z","pushed_at":"2015-05-13T11:51:07Z","git_url":"git://github.com/theforeman/foreman.git","ssh_url":"git@github.com:theforeman/foreman.git","clone_url":"https://github.com/theforeman/foreman.git","svn_url":"https://github.com/theforeman/foreman","homepage":"http://theforeman.org","size":82972,"stargazers_count":756,"watchers_count":756,"language":"Ruby","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":391,"mirror_url":null,"open_issues_count":80,"forks":391,"open_issues":80,"watchers":756,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/2377"},"html":{"href":"https://github.com/theforeman/foreman/pull/2377"},"issue":{"href":"https://api.github.com/repos/theforeman/foreman/issues/2377"},"comments":{"href":"https://api.github.com/repos/theforeman/foreman/issues/2377/comments"},"review_comments":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/2377/comments"},"review_comment":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/theforeman/foreman/pulls/2377/commits"},"statuses":{"href":"https://api.github.com/repos/theforeman/foreman/statuses/1a9fe5bf46e54f229d90b55694d2032efb588f1c"}}}}