Skip to content

Commit

Permalink
Added comment to explain usage of optional values in PushHandlers.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
ikurek committed Apr 21, 2022
1 parent 5b3ce39 commit cf7b9cb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ios/Classes/handlers/PushHandlers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,9 @@ public class PushHandlers: NSObject {
/// This function will callback the with the push channel for the channelName and client handle you provide.
private static func getPushChannel(ably: AblyFlutter, call: FlutterMethodCall, result: @escaping FlutterResult) -> ARTPushChannel? {
let ablyMessage = call.arguments as! AblyFlutterMessage

/// Using `guard let handle` in that case caused compilation errors for some users
/// See https://github.com/ably/ably-flutter/issues/347 for more information and
let optionalHandle: NSNumber? = ablyMessage.handle
var optionalChannelName: String?

Expand Down

0 comments on commit cf7b9cb

Please sign in to comment.