ionic-team / ionic-v1

The repo for Ionic 1.x. For the latest version of Ionic, please see https://github.com/ionic-team/ionic
Other
192 stars 187 forks source link

fix(refresherController): do not assume that user-supplied promises have a… #267

Open floriansimon1 opened 7 years ago

floriansimon1 commented 7 years ago

… finally() method

Fallback to transparent then() instead

Short description of what this resolves:

ionicRefresher, or whatever it's called, expects promises returned in refresh callbacks to have finally() methods. When I return a native promise from these callbacks, I want Ionic to not crash my application

Changes proposed in this pull request:

When finally() is not available, fallback to using a transparent then()

Ionic Version: 1.x