Skip to content

Commit d9f39b1

Browse files
committed
Fix "Supertypes through typealias cannot be nullable. This will become an error in language version 2.3."
1 parent cd743eb commit d9f39b1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

libraries/apollo-runtime/src/appleMain/kotlin/com/apollographql/apollo/network/NetworkObserver.apple.kt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,11 @@ import platform.Network.nw_path_monitor_set_queue
77
import platform.Network.nw_path_monitor_set_update_handler
88
import platform.Network.nw_path_monitor_start
99
import platform.Network.nw_path_monitor_t
10-
import platform.Network.nw_path_monitor_update_handler_t
1110
import platform.Network.nw_path_status_satisfied
1211
import platform.Network.nw_path_t
1312
import platform.darwin.dispatch_queue_create
1413

15-
internal class AppleNetworkObserver: NetworkObserver, nw_path_monitor_update_handler_t {
14+
internal class AppleNetworkObserver: NetworkObserver, ((nw_path_t) -> Unit) {
1615
var monitor: nw_path_monitor_t = null
1716
var listener: NetworkObserver.Listener? = null
1817

@@ -36,4 +35,4 @@ internal class AppleNetworkObserver: NetworkObserver, nw_path_monitor_update_han
3635
override fun invoke(p1: nw_path_t) {
3736
listener?.networkChanged((nw_path_get_status(p1) == nw_path_status_satisfied))
3837
}
39-
}
38+
}

0 commit comments

Comments
 (0)