Add assertion to check if delegate is nil

This commit is contained in:
Sergey Abramchuk
2020-06-10 08:58:50 +03:00
parent 8fa49f5e57
commit d916ec4b96
@@ -87,6 +87,8 @@
}
- (void)connectUsingPacketFlow:(id<OpenVPNAdapterPacketFlow>)packetFlow {
NSAssert(self.delegate != nil, @"delegate property shouldn't be nil, set it before trying to establish connection.");
self.packetFlowBridge.packetFlow = packetFlow;
dispatch_queue_attr_t attributes = dispatch_queue_attr_make_with_qos_class(DISPATCH_QUEUE_SERIAL, QOS_CLASS_UTILITY, 0);