             
         case let .unprovisionedDevice(beacon):
             
-            return Data([GAPBeaconType.unprovisionedDevice.rawValue]) + beacon.data
+            return beacon.data
             
         case let .secureNetwork(beacon):
             
-            return Data([GAPBeaconType.secureNetwork.rawValue]) + beacon.data
+            return beacon.data
             
         }
     }

    
    public init?(data: Data) {
        
        guard data.count >= type(of: self).typeLength
            else { return nil }
        
        guard let type = GAPBeaconType(rawValue: data[0])
            else { return nil }
        
        let reducedData = data.subdata(in: (1 ..< data.count))
        
        switch type {

        case .unprovisionedDevice:
            
            guard let beacon = GAPUnprovisionedDeviceBeacon(data: reducedData)
                else { return nil }
            
            self = .unprovisionedDevice(beacon)
            
        case .secureNetwork:
            
            guard let beacon = GAPSecureNetworkBeacon(data: reducedData)
                else { return nil }
            
            self = .secureNetwork(beacon)

    
    public init?(data: Data) {
        
        guard data.count == type(of: self).length,
            let type = GAPLEDeviceAddressType(rawValue: data[6])
            else { return nil }
        
        let address = Address(bytes: (data[0], data[1], data[2], data[3], data[4], data[5]))
