feat: Bump Kotlin to 1.5.30 and KotlinX Coroutines to 1.5.1#162
Conversation
| callbackFlow { | ||
| setOnMarkerClickListener { | ||
| offerCatching(it) | ||
| trySend(it).isSuccess |
There was a problem hiding this comment.
Just curious - why do only some of these use .isSuccess?
There was a problem hiding this comment.
This is because some callback methods return a boolean (like in this case onMarkerClick). offerCatching returned boolean which was being swallowed in void callback methods. The implementation here of returning isSuccess should be equivalent to calling offerCatching.
Looking at this method a bit more though, I think the return value should be customizable by the caller. As it is currently implemented, if the marker is clicked and the channel is able to send the marker object, the default behavior of moving the camera to center on the marker and displaying an info window will always occur. Will file an issue for this.
There was a problem hiding this comment.
Ah, ok - thanks. That's what I initially thought but I was confusing myself by looking at the wrong methods - in this case, setOnMarkerClickListener, which returns void instead of onMarkerClick, which returns boolean.
I think the return value should be customizable by the caller.
I agree, that makes sense 👍
Codecov Report
@@ Coverage Diff @@
## main #162 +/- ##
======================================
Coverage ? 0.00%
======================================
Files ? 28
Lines ? 334
Branches ? 6
======================================
Hits ? 0
Misses ? 334
Partials ? 0 Continue to review full report at Codecov.
|
# [3.2.0](v3.1.0...v3.2.0) (2021-09-16) ### Features * Bump Kotlin to 1.5.30 and KotlinX Coroutines to 1.5.1 ([#162](#162)) ([df90327](df90327))
|
🎉 This PR is included in version 3.2.0 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
Bump Kotlin and KotlinX Couroutines to 1.5.30 and 1.5.1, respectively.
Fixes #158 🦕