Skip to content

Commit

Permalink
Sendable progress callback.
Browse files Browse the repository at this point in the history
  • Loading branch information
buh committed Oct 12, 2023
1 parent d82e827 commit 24c92bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/ZipPinch/URLSession+ZIPEntry.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ public struct ZIPProgress {
public let bufferSize: Int

/// Callback progress with a value between 0 and 1.
public let callback: (Double) -> Void
public let callback: @Sendable (Double) -> Void

/// Creates the progress container.
/// - Parameters:
/// - bufferSize: the number of bytes of the buffer (64 Kb by default).
/// - callback: the callback progress with a value between 0 and 1.
public init(bufferSize: Int = 0xffff, callback: @escaping (Double) -> Void) {
public init(bufferSize: Int = 0xffff, callback: @Sendable @escaping (Double) -> Void) {
self.bufferSize = bufferSize
self.callback = callback
}
Expand Down

0 comments on commit 24c92bc

Please sign in to comment.