         }
     }
 
-    /// Each task might have a dependency. The task automatically unsubscribes
+    /// A task might have a dependency. The task automatically unsubscribes
     /// from the dependency when it gets cancelled, and also updates the
     /// priority of the subscription to the dependency when its own
     /// priority is updated.

        switch event {
        case let .value(_, isCompleted):
            if isCompleted {
                transition(to: .completed)
            }
        case .progress:
            break // Simply send the event
        case .error:
            transition(to: .failed)
        }

        for context in subscriptions.values {

        guard !isDisposed else { return }

        if subscriptions.isEmpty {
            terminate(reason: .cancelled)
        } else {
            updatePriority()
        }
