From 1e92a99b7f6926180d724ab5c3e29f03ede60e43 Mon Sep 17 00:00:00 2001 From: matthijs2704 Date: Sun, 2 Oct 2016 17:22:21 +0200 Subject: [PATCH] Fixes wrong imports --- Sources/VaporAPNS/VaporAPNS.swift | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/Sources/VaporAPNS/VaporAPNS.swift b/Sources/VaporAPNS/VaporAPNS.swift index 9e56f27..651051e 100644 --- a/Sources/VaporAPNS/VaporAPNS.swift +++ b/Sources/VaporAPNS/VaporAPNS.swift @@ -1,17 +1,13 @@ -import HTTP -import Transport import Foundation import SwiftString import JSON -import Vapor import CCurl -import Jay import JSON +import Jay public class VaporAPNS { private var options: Options - private var httpClient: Client, Parser>? private var curlHandle: UnsafeMutableRawPointer public init(certPath: String, keyPath: String, options: Options? = nil) throws { @@ -128,7 +124,7 @@ public class VaporAPNS { } } - public func toNullTerminatedUtf8String(_ str: Bytes) -> Data? { + public func toNullTerminatedUtf8String(_ str: [UTF8.CodeUnit]) -> Data? { // let cString = str.cString(using: String.Encoding.utf8) return str.withUnsafeBufferPointer() { buffer -> Data? in return buffer.baseAddress != nil ? Data(bytes: buffer.baseAddress!, count: buffer.count) : nil