Skip to content

Commit 12124bf

Browse files
committed
Remove change param
1 parent b0639f3 commit 12124bf

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

Sources/NativePusher.swift

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,6 @@ import Foundation
199199
requestQueue.tasks += { _, next in
200200
self.modifySubscription(
201201
interests: interests,
202-
change: change,
203202
successCallback: next
204203
)
205204
}
@@ -235,7 +234,7 @@ import Foundation
235234
- parameter change: Whether to subscribe or unsubscribe
236235
- parameter callback: Callback to be called upon success
237236
*/
238-
private func modifySubscription(interests: Array<String>, change: SubscriptionChange, successCallback: @escaping (Any?) -> Void) {
237+
private func modifySubscription(interests: Array<String>, successCallback: @escaping (Any?) -> Void) {
239238
guard
240239
let clientId = clientId,
241240
let pusherAppKey = pusherAppKey
@@ -247,8 +246,8 @@ import Foundation
247246

248247
let url = "\(CLIENT_API_V1_ENDPOINT)/clients/\(clientId)/interests/"
249248
let params: [String: Any] = ["app_key": pusherAppKey, "interests": interests]
250-
let request = self.setRequest(url: url, params: params, change: change)
251-
self.modifySubscription(interests: interests, request: request, change: change, successCallback: successCallback)
249+
let request = self.setRequest(url: url, params: params, change: .setSubscriptions)
250+
self.modifySubscription(interests: interests, request: request, change: .setSubscriptions, successCallback: successCallback)
252251
}
253252

254253
private func modifySubscription(interests: Array<String>, request: URLRequest, change: SubscriptionChange, successCallback: @escaping (Any?) -> Void) {

0 commit comments

Comments
 (0)