From 2113b3de57ae974eeb5fa114cb1522773b569b11 Mon Sep 17 00:00:00 2001 From: codecat15 Date: Thu, 4 Jun 2020 20:28:39 -0500 Subject: [PATCH] updating the access of the init function --- HttpUtility/HttpUtility.swift | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/HttpUtility/HttpUtility.swift b/HttpUtility/HttpUtility.swift index 80619f8..130c0a1 100644 --- a/HttpUtility/HttpUtility.swift +++ b/HttpUtility/HttpUtility.swift @@ -34,25 +34,25 @@ enum HttpMethods case delete } -struct HttpUtility +public struct HttpUtility { private var _token: String? = nil private var _customJsonDecoder: JSONDecoder? = nil - init(token: String?){ + public init(token: String?){ _token = token } - init(token: String?, decoder: JSONDecoder?){ + public init(token: String?, decoder: JSONDecoder?){ _token = token _customJsonDecoder = decoder } - init(WithJsonDecoder decoder: JSONDecoder){ + public init(WithJsonDecoder decoder: JSONDecoder){ _customJsonDecoder = decoder } - init(){} + public init(){} func request(requestUrl: URL, method: HttpMethods, requestBody: Data? = nil, resultType: T.Type, completionHandler:@escaping(Result)-> Void) {