Skip to content

Commit

Permalink
Handle observing of predisposed signals.
Browse files Browse the repository at this point in the history
  • Loading branch information
srdanrasic committed Dec 11, 2019
1 parent 7b87f0c commit 016b398
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions ReactiveKit.podspec
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
Pod::Spec.new do |s|
s.name = "ReactiveKit"
s.version = "3.15.3"
s.version = "3.15.4"
s.summary = "A Swift Reactive Programming Framework"
s.description = "ReactiveKit is a Swift framework for reactive and functional reactive programming."
s.homepage = "https://github.com/DeclarativeHub/ReactiveKit"
s.license = 'MIT'
s.author = { "Srdan Rasic" => "[email protected]" }
s.source = { :git => "https://github.com/DeclarativeHub/ReactiveKit.git", :tag => "v3.15.3" }
s.source = { :git => "https://github.com/DeclarativeHub/ReactiveKit.git", :tag => "v3.15.4" }

s.ios.deployment_target = '8.0'
s.osx.deployment_target = '10.11'
Expand Down
6 changes: 5 additions & 1 deletion Sources/Observer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,11 @@ public final class AtomicObserver<Element, Error: Swift.Error>: ObserverProtocol
public func attach(_ producer: Signal<Element, Error>.Producer) {
let disposable = producer(self)
disposablesQueue.async {
self.upstreamDisposables.append(disposable)
if self.isDisposed {
disposable.dispose()
} else {
self.upstreamDisposables.append(disposable)
}
}
}

Expand Down
2 changes: 1 addition & 1 deletion Supporting Files/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>3.15.3</string>
<string>3.15.4</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down

0 comments on commit 016b398

Please sign in to comment.