File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 1
1
#Upcoming Release
2
2
3
+ #4 .0.1
4
+ ** API Changes:**
5
+
6
+ - ` dispatch(_ stream:) ` now returns a subscription reference.
7
+
3
8
#3 .0.6
4
9
** Breaking API Changes:**
5
10
Original file line number Diff line number Diff line change @@ -35,9 +35,12 @@ open class Store<ObservableProperty: ObservablePropertyType> {
35
35
}
36
36
}
37
37
38
- public func dispatch< S: StreamType > ( _ stream: S ) where S. ValueType: Action {
39
- disposeBag += stream. subscribe { [ unowned self] action in
38
+ @discardableResult
39
+ public func dispatch< S: StreamType > ( _ stream: S ) -> SubscriptionReferenceType ? where S. ValueType: Action {
40
+ let disposable = stream. subscribe { [ unowned self] action in
40
41
self . dispatch ( action)
41
42
}
43
+ disposeBag += disposable
44
+ return disposable
42
45
}
43
46
}
You can’t perform that action at this time.
0 commit comments