This commit is contained in:
Михаил Капелько
2023-12-28 12:45:20 +03:00
parent d66e42964d
commit eb29bb6d9e
2 changed files with 15 additions and 15 deletions

View File

@@ -1,15 +0,0 @@
import Combine
public extension Bus {
final class Sender<T> {
var subscriptions = [AnyCancellable]()
public init(
_ key: String,
_ node: AnyPublisher<T, Never>,
opt: [Option] = []
) {
Bus.send(key, node, opt: opt, sub: &subscriptions)
}
}
}

View File

@@ -13,3 +13,18 @@ public extension Bus {
} }
} }
} }
import Combine
public extension Bus {
final class Sender<T> {
var subscriptions = [AnyCancellable]()
public init(
_ key: String,
_ node: AnyPublisher<T, Never>,
opt: [Option] = []
) {
Bus.send(key, node, opt: opt, sub: &subscriptions)
}
}
}