From 0a1f33823adc9cd358b763051a9eaf51493f2fd3 Mon Sep 17 00:00:00 2001 From: Davide De Rosa Date: Fri, 2 Jul 2021 11:22:20 +0200 Subject: [PATCH] Return error in install completion handler Fixes #206 --- CHANGELOG.md | 6 ++++++ TunnelKit/Sources/Protocols/OpenVPN/OpenVPNProvider.swift | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fbd97e3..5c95668 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## Unreleased + +### Fixed + +- Return error in install completion handler. [#206](https://github.com/passepartoutvpn/tunnelkit/issues/206) + ## 3.3.2 (2021-06-26) ### Fixed diff --git a/TunnelKit/Sources/Protocols/OpenVPN/OpenVPNProvider.swift b/TunnelKit/Sources/Protocols/OpenVPN/OpenVPNProvider.swift index 69f4dcc..0d9d85c 100644 --- a/TunnelKit/Sources/Protocols/OpenVPN/OpenVPNProvider.swift +++ b/TunnelKit/Sources/Protocols/OpenVPN/OpenVPNProvider.swift @@ -144,7 +144,7 @@ public class OpenVPNProvider: VPNProvider { } install(configuration: configuration) { (error) in guard error == nil else { - completionHandler?(nil) + completionHandler?(error) return } let connectBlock = {