Skip to content

Commit d763fad

Browse files
committed
no need to capture completion hander in wrapper
1 parent 28fad62 commit d763fad

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Source/SocketIO/Client/SocketIOClient.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ open class SocketIOClient : NSObject, SocketIOClientSpec {
296296

297297
func emit(_ data: [Any], ack: Int? = nil, binary: Bool = true, isAck: Bool = false, completion: (() -> ())? = nil) {
298298
// wrap the completion handler so it always runs async via handlerQueue
299-
let wrappedCompletion = {[weak self, completion] in
299+
let wrappedCompletion = {[weak self] in
300300
guard let this = self else { return }
301301
this.manager?.handleQueue.async { completion?() }
302302
}

0 commit comments

Comments
 (0)