File tree Expand file tree Collapse file tree 1 file changed +8
-12
lines changed
Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Original file line number Diff line number Diff line change @@ -162,7 +162,14 @@ import Foundation
162162 - parameter interests: the name of the interests you want to subscribe to
163163 */
164164 open func setSubscriptions( interests: Array < String > ) {
165- addSubscriptionChangeToTaskQueue ( interests: interests, change: . setSubscriptions)
165+ requestQueue. tasks += { _, next in
166+ self . modifySubscription (
167+ interests: interests,
168+ successCallback: next
169+ )
170+ }
171+
172+ requestQueue. run ( )
166173 }
167174
168175 /**
@@ -195,17 +202,6 @@ import Foundation
195202 requestQueue. run ( )
196203 }
197204
198- private func addSubscriptionChangeToTaskQueue( interests: Array < String > , change: SubscriptionChange ) {
199- requestQueue. tasks += { _, next in
200- self . modifySubscription (
201- interests: interests,
202- successCallback: next
203- )
204- }
205-
206- requestQueue. run ( )
207- }
208-
209205 /**
210206 Makes either a POST or DELETE request for a given interest
211207 - parameter interest: The name of the interest to be subscribed to / unsunscribed from
You can’t perform that action at this time.
0 commit comments