Tonkpils / ember-sweetalert

Ember CLI addon for SweetAlert2
MIT License
19 stars 10 forks source link

Uncaught (in promise) #5

Closed herzzanu closed 6 years ago

herzzanu commented 7 years ago

I'm getting the following errors when clicking the cancel button or the overlay

image

sametersan commented 7 years ago

You can use like this;

.then((confirm)=> { console.log(confirm); },(dismiss)=>{ console.log(dismiss); });

victor95pc commented 7 years ago

it's normal, take a look at sweet alert README file and you will see it, I prefer writing like this when I don't care about the cancel button.

promise.then((confirm)=> {
console.log(confirm);
}).catch(swal.noop);

Sweet Alert 2 README

@herzzanu can you close it?

lindyhopchris commented 6 years ago

Closing this as the latest development version of this package upgrades to SweetAlert 7, for which this isn't an issue.