Skip to content

Commit

Permalink
Fix an issue with state being writable
Browse files Browse the repository at this point in the history
  • Loading branch information
kean committed Oct 27, 2024
1 parent 2086dc6 commit bf79725
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Sources/Nuke/ImageTask.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ import UIKit
import AppKit
#endif

// TODO: try to make another internal instance that is isolated
// - possible make `ImageTask` a struct? then no questions about retaining it

/// A task performed by the ``ImagePipeline``.
///
/// The pipeline maintains a strong reference to the task until the request
Expand Down Expand Up @@ -60,7 +63,7 @@ public final class ImageTask: Hashable, @unchecked Sendable {

/// The current state of the task.
@ImagePipelineActor
public var state: State = .running
public private(set) var state: State = .running

/// The state of the image task.
public enum State: Sendable {
Expand Down

0 comments on commit bf79725

Please sign in to comment.