{"action":"created","issue":{"url":"https://api.github.com/repos/dart-lang/linter/issues/1200","repository_url":"https://api.github.com/repos/dart-lang/linter","labels_url":"https://api.github.com/repos/dart-lang/linter/issues/1200/labels{/name}","comments_url":"https://api.github.com/repos/dart-lang/linter/issues/1200/comments","events_url":"https://api.github.com/repos/dart-lang/linter/issues/1200/events","html_url":"https://github.com/dart-lang/linter/issues/1200","id":367006222,"node_id":"MDU6SXNzdWUzNjcwMDYyMjI=","number":1200,"title":"Passing setters with use_setters_to_change_properties","user":{"login":"maxlapides","id":1874682,"node_id":"MDQ6VXNlcjE4NzQ2ODI=","avatar_url":"https://avatars3.githubusercontent.com/u/1874682?v=4","gravatar_id":"","url":"https://api.github.com/users/maxlapides","html_url":"https://github.com/maxlapides","followers_url":"https://api.github.com/users/maxlapides/followers","following_url":"https://api.github.com/users/maxlapides/following{/other_user}","gists_url":"https://api.github.com/users/maxlapides/gists{/gist_id}","starred_url":"https://api.github.com/users/maxlapides/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maxlapides/subscriptions","organizations_url":"https://api.github.com/users/maxlapides/orgs","repos_url":"https://api.github.com/users/maxlapides/repos","events_url":"https://api.github.com/users/maxlapides/events{/privacy}","received_events_url":"https://api.github.com/users/maxlapides/received_events","type":"User","site_admin":false},"labels":[{"id":165917057,"node_id":"MDU6TGFiZWwxNjU5MTcwNTc=","url":"https://api.github.com/repos/dart-lang/linter/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-10-04T23:24:23Z","updated_at":"2018-10-22T22:21:28Z","closed_at":"2018-10-19T23:38:30Z","author_association":"NONE","body":"This example does NOT create a lint warning:\r\n\r\n```\r\nclass MyClass {\r\n  bool isOn;\r\n\r\n  // this is good!\r\n  void _setIsOn(bool newIsOn) => isOn = newIsOn;\r\n\r\n  AnotherClass create() {\r\n    return AnotherClass(setIsOn: _setIsOn);\r\n  }\r\n}\r\n\r\nclass AnotherClass {\r\n  Function setIsOn;\r\n  AnotherClass({this.setIsOn});\r\n}\r\n```\r\n\r\nBut when I don't use the lambda expression syntax, I do get a lint warning:\r\n\r\n```\r\nclass MyClass {\r\n  bool isOn;\r\n\r\n  // this is bad!\r\n  void _setIsOn(bool newIsOn) {\r\n    isOn = newIsOn;\r\n  }\r\n\r\n  AnotherClass create() {\r\n    return AnotherClass(setIsOn: _setIsOn);\r\n  }\r\n}\r\n\r\nclass AnotherClass {\r\n  Function setIsOn;\r\n  AnotherClass({this.setIsOn});\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/dart-lang/linter/issues/comments/432011627","html_url":"https://github.com/dart-lang/linter/issues/1200#issuecomment-432011627","issue_url":"https://api.github.com/repos/dart-lang/linter/issues/1200","id":432011627,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMjAxMTYyNw==","user":{"login":"srawlins","id":103167,"node_id":"MDQ6VXNlcjEwMzE2Nw==","avatar_url":"https://avatars3.githubusercontent.com/u/103167?v=4","gravatar_id":"","url":"https://api.github.com/users/srawlins","html_url":"https://github.com/srawlins","followers_url":"https://api.github.com/users/srawlins/followers","following_url":"https://api.github.com/users/srawlins/following{/other_user}","gists_url":"https://api.github.com/users/srawlins/gists{/gist_id}","starred_url":"https://api.github.com/users/srawlins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srawlins/subscriptions","organizations_url":"https://api.github.com/users/srawlins/orgs","repos_url":"https://api.github.com/users/srawlins/repos","events_url":"https://api.github.com/users/srawlins/events{/privacy}","received_events_url":"https://api.github.com/users/srawlins/received_events","type":"User","site_admin":false},"created_at":"2018-10-22T22:21:28Z","updated_at":"2018-10-22T22:21:28Z","author_association":"MEMBER","body":"I'm not sure actually... you'd have to test out if you can tear off a setter. Good question."}}
{"actor":{"display_login":"srawlins"}}