diff --git a/Sources/App/configure.swift b/Sources/App/configure.swift index aec29f8..098d84a 100755 --- a/Sources/App/configure.swift +++ b/Sources/App/configure.swift @@ -136,6 +136,7 @@ private func readElements(from url: URL) throws -> [Timestamped] where T: var result: [Timestamped] = [] var currentIndex = data.startIndex + var skippedValues = 0 while currentIndex < data.endIndex { let startIndexOfTimestamp = currentIndex + byteCountLength guard startIndexOfTimestamp <= data.endIndex else { @@ -159,14 +160,18 @@ private func readElements(from url: URL) throws -> [Timestamped] where T: let timestamp = try decoder.decode(Double.self, from: timestampData) let date = Date(timeIntervalSince1970: timestamp) let elementData = data[currentIndex..