{"action":"created","issue":{"url":"https://api.github.com/repos/platanus/froggo/issues/121","repository_url":"https://api.github.com/repos/platanus/froggo","labels_url":"https://api.github.com/repos/platanus/froggo/issues/121/labels{/name}","comments_url":"https://api.github.com/repos/platanus/froggo/issues/121/comments","events_url":"https://api.github.com/repos/platanus/froggo/issues/121/events","html_url":"https://github.com/platanus/froggo/pull/121","id":315636554,"number":121,"title":"feat(pr-relations): change create pr relation command for a service","user":{"login":"poxvirus","id":2238663,"avatar_url":"https://avatars0.githubusercontent.com/u/2238663?v=4","gravatar_id":"","url":"https://api.github.com/users/poxvirus","html_url":"https://github.com/poxvirus","followers_url":"https://api.github.com/users/poxvirus/followers","following_url":"https://api.github.com/users/poxvirus/following{/other_user}","gists_url":"https://api.github.com/users/poxvirus/gists{/gist_id}","starred_url":"https://api.github.com/users/poxvirus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poxvirus/subscriptions","organizations_url":"https://api.github.com/users/poxvirus/orgs","repos_url":"https://api.github.com/users/poxvirus/repos","events_url":"https://api.github.com/users/poxvirus/events{/privacy}","received_events_url":"https://api.github.com/users/poxvirus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"poxvirus","id":2238663,"avatar_url":"https://avatars0.githubusercontent.com/u/2238663?v=4","gravatar_id":"","url":"https://api.github.com/users/poxvirus","html_url":"https://github.com/poxvirus","followers_url":"https://api.github.com/users/poxvirus/followers","following_url":"https://api.github.com/users/poxvirus/following{/other_user}","gists_url":"https://api.github.com/users/poxvirus/gists{/gist_id}","starred_url":"https://api.github.com/users/poxvirus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poxvirus/subscriptions","organizations_url":"https://api.github.com/users/poxvirus/orgs","repos_url":"https://api.github.com/users/poxvirus/repos","events_url":"https://api.github.com/users/poxvirus/events{/privacy}","received_events_url":"https://api.github.com/users/poxvirus/received_events","type":"User","site_admin":false},"assignees":[{"login":"poxvirus","id":2238663,"avatar_url":"https://avatars0.githubusercontent.com/u/2238663?v=4","gravatar_id":"","url":"https://api.github.com/users/poxvirus","html_url":"https://github.com/poxvirus","followers_url":"https://api.github.com/users/poxvirus/followers","following_url":"https://api.github.com/users/poxvirus/following{/other_user}","gists_url":"https://api.github.com/users/poxvirus/gists{/gist_id}","starred_url":"https://api.github.com/users/poxvirus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poxvirus/subscriptions","organizations_url":"https://api.github.com/users/poxvirus/orgs","repos_url":"https://api.github.com/users/poxvirus/repos","events_url":"https://api.github.com/users/poxvirus/events{/privacy}","received_events_url":"https://api.github.com/users/poxvirus/received_events","type":"User","site_admin":false}],"milestone":null,"comments":0,"created_at":"2018-04-18T20:47:24Z","updated_at":"2018-04-18T20:47:52Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/platanus/froggo/pulls/121","html_url":"https://github.com/platanus/froggo/pull/121","diff_url":"https://github.com/platanus/froggo/pull/121.diff","patch_url":"https://github.com/platanus/froggo/pull/121.patch"},"body":"Cada vez que se creaban las relaciones de un PR (pull request), solo se creaban un tipo de relación (`merged_by` o `reviewer`). El problema estaba en que el método que creaba las relaciones de review (`creates_from_reviews`) borraba todas las relaciones del PR, no solamente las de tipo `reviewer`.\r\n\r\nSe aprovecho de cambiar el comando por un servicio, ya que cada vez que hay un cambio en la información de merge de un PR o sus reviews se actualizaban todos los tipos de relaciones que tiene el PR. Estas relaciones son independientes, por lo que las separé.\r\n\r\n## Cambios\r\n\r\n- Cambié el comando `CreatePullRelation` por `PullRequestRelationService`."},"comment":{"url":"https://api.github.com/repos/platanus/froggo/issues/comments/382524231","html_url":"https://github.com/platanus/froggo/pull/121#issuecomment-382524231","issue_url":"https://api.github.com/repos/platanus/froggo/issues/121","id":382524231,"user":{"login":"poxvirus","id":2238663,"avatar_url":"https://avatars0.githubusercontent.com/u/2238663?v=4","gravatar_id":"","url":"https://api.github.com/users/poxvirus","html_url":"https://github.com/poxvirus","followers_url":"https://api.github.com/users/poxvirus/followers","following_url":"https://api.github.com/users/poxvirus/following{/other_user}","gists_url":"https://api.github.com/users/poxvirus/gists{/gist_id}","starred_url":"https://api.github.com/users/poxvirus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poxvirus/subscriptions","organizations_url":"https://api.github.com/users/poxvirus/orgs","repos_url":"https://api.github.com/users/poxvirus/repos","events_url":"https://api.github.com/users/poxvirus/events{/privacy}","received_events_url":"https://api.github.com/users/poxvirus/received_events","type":"User","site_admin":false},"created_at":"2018-04-18T20:47:52Z","updated_at":"2018-04-18T20:47:52Z","author_association":"COLLABORATOR","body":"![](https://github.trello.services/images/mini-trello-icon.png) [Las relaciones se están creando mal](https://trello.com/c/34OHRtX8/88-las-relaciones-se-est%C3%A1n-creando-mal)"}}
{"actor":{"display_login":"poxvirus"}}