When an image fails to load, a registered Logger should receive the throwable describing what happened. Unfortunately, RealImageLoader's implementation does not do this, so as far as I can tell there is no reason a logger would ever be called with a non-null throwable argument.
This is a quick and dirty proof of concept of what a fix might look like. I suspect the string was previously generaetd in a lambda to avoid generating the string in cases where it won't actually be used (a performance benefit), and this PR as currently implemented loses that benefit. I would also add an extension function that both lambdifies the string and doesn't lose the throwable before merging this.
When an image fails to load, a registered Logger should receive the throwable describing what happened. Unfortunately, RealImageLoader's implementation does not do this, so as far as I can tell there is no reason a logger would ever be called with a non-null throwable argument.
This is a quick and dirty proof of concept of what a fix might look like. I suspect the string was previously generaetd in a lambda to avoid generating the string in cases where it won't actually be used (a performance benefit), and this PR as currently implemented loses that benefit. I would also add an extension function that both lambdifies the string and doesn't lose the throwable before merging this.