     }
     
     private func statistics(at date: Date, id: HKQuantityTypeIdentifier, option: HKStatisticsOptions, completion: @escaping Callback<HKStatistics?>) {
-        
         statisticsCollection(at: date, id: id, option: option) { result in
             switch result {
             case .failure(let error): completion(Result.failure(error))
             case .success(let collection):
-                
                 guard let collection = collection else {
                     completion(Result.success(nil))
                     return

    }
    
    public func deleteData(at date: Date, id: HKQuantityTypeIdentifier, completion: @escaping Callback<Bool>) {
        let resultsHandler = { (_: HKSampleQuery, samples: [HKSample]?, error: Error?) in
            if let error = error {
                completion(Result.failure(SHKError.from(error)))
                return
            }
            guard let items = (samples?.filter { date.isInSameDay(at: $0.startDate) }), items.count > 0 else {
                // Nothing to delete
                completion(Result.success(true))
                return
            }
            
            self.delete(samples: items, completion: completion)
        }
        
        let query = HKSampleQuery(
            sampleType: id.type,
            predicate: predicateForOneDay(date: date),
            limit: HKObjectQueryNoLimit,
            sortDescriptors: nil,
            resultsHandler: resultsHandler)
        store.execute(query)
    }
    

        return HKQuery.predicateForSamples(
            withStart: date.startOfDay,
            end: date.endOfDay,
            options: .strictStartDate)
    }
}

