{"comment":{"url":"https://api.github.com/repos/ataulm/art-collector/comments/31070162","html_url":"https://github.com/ataulm/art-collector/commit/134f37f08d285d7cc8bfed01648d805f95f76d91#commitcomment-31070162","id":31070162,"node_id":"MDEzOkNvbW1pdENvbW1lbnQzMTA3MDE2Mg==","user":{"login":"ataulm","id":2678555,"node_id":"MDQ6VXNlcjI2Nzg1NTU=","avatar_url":"https://avatars1.githubusercontent.com/u/2678555?v=4","gravatar_id":"","url":"https://api.github.com/users/ataulm","html_url":"https://github.com/ataulm","followers_url":"https://api.github.com/users/ataulm/followers","following_url":"https://api.github.com/users/ataulm/following{/other_user}","gists_url":"https://api.github.com/users/ataulm/gists{/gist_id}","starred_url":"https://api.github.com/users/ataulm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ataulm/subscriptions","organizations_url":"https://api.github.com/users/ataulm/orgs","repos_url":"https://api.github.com/users/ataulm/repos","events_url":"https://api.github.com/users/ataulm/events{/privacy}","received_events_url":"https://api.github.com/users/ataulm/received_events","type":"User","site_admin":false},"position":24,"line":24,"path":"app/src/main/java/com/ataulm/artcollector/paintings/PaintingsComponent.kt","commit_id":"134f37f08d285d7cc8bfed01648d805f95f76d91","created_at":"2018-10-27T17:49:43Z","updated_at":"2018-10-27T17:49:43Z","author_association":"OWNER","body":"This extension function on PaintingsActivity instantiates a new instance of `DaggerPaintingsComponent` (which is generated by Dagger).\r\n\r\nWe don't need to pass an instance of `PaintingsModule` it has no dependencies.\r\n\r\n(The `activity(activity: PaintingsActivity)` is unnecessary at this stage, and is removed in the next commit but...)\r\n\r\nIf we _did_ need a context or activity to create other objects in `PaintingsModule` there's two ways we could do it:\r\n\r\n- pass the activity as a constructor dependency to `PaintingsModule`, which would require us to instantiate it ourselves below\r\n- use the `@BindsInstance` on the `activity(activity:Activity)` method in the `Builder` as above\r\n\r\n>@BindsInstance methods should be preferred to writing a @Module with constructor arguments and immediately providing those values.\r\n\r\nhttps://google.github.io/dagger/users-guide.html#binding-instances"}}
{"actor":{"display_login":"ataulm"}}