Skip to content

Commit

Permalink
use remove function instead of removeSubscription 馃悰 (#365)
Browse files Browse the repository at this point in the history
馃憤 Done, but it might be a while before this gets released in an official version. Feel free to install against the commit or master branch. (and check out the README on front page)
  • Loading branch information
mouessam committed Dec 27, 2022
1 parent 7acd339 commit 578f55e
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions js/PaymentRequest/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -409,16 +409,12 @@ export default class PaymentRequest {

_removeEventListeners() {
// Internal Events
DeviceEventEmitter.removeSubscription(this._userDismissSubscription);
DeviceEventEmitter.removeSubscription(this._userAcceptSubscription);
this._userDismissSubscription.remove()
this._userAcceptSubscription.remove()

if (IS_IOS) {
DeviceEventEmitter.removeSubscription(
this._shippingAddressChangeSubscription
);
DeviceEventEmitter.removeSubscription(
this._shippingOptionChangeSubscription
);
this._shippingAddressChangeSubscription.remove()
this._shippingOptionChangeSubscription.remove()
}
}

Expand Down

0 comments on commit 578f55e

Please sign in to comment.