You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The call subscribe { recordList ->
database.transaction {
database.zone_RecordQueries.delete_by_zone_id(domainName)
insertRows(recordList)
}
} is returning a value that is ignored.
I think the message should change to show only subscribe in this case, since that's the name of the method that was called, and did not have it's return value checked. The contents of {} block is not relevant. Likewise for example observeOn(Schedulers.io()) only observeOn needs to be shown in the message.
The text was updated successfully, but these errors were encountered:
3flex
changed the title
IgnoredReturnValue should only show name of
IgnoredReturnValue should only report name of method/function called
Sep 5, 2020
Expected Behavior of the rule
IgnoredReturnValue message should only show the name of the call that did not have its return value checked, not the entire expression.
Context
IgnoredReturnValue
is flagged for this code:.subscribe { recordList -> database.transaction { database.zone_RecordQueries.delete_by_zone_id(domainName) insertRows(recordList) } }
And the message reported is
I think the message should change to show only
subscribe
in this case, since that's the name of the method that was called, and did not have it's return value checked. The contents of{}
block is not relevant. Likewise for exampleobserveOn(Schedulers.io())
onlyobserveOn
needs to be shown in the message.The text was updated successfully, but these errors were encountered: