lundi 27 août 2018

ember save call not going to success block

I am using ember save call on model to persist and invoke my REST call.

_model.save().then(() =>{
   console.log("success");
 }, (error) {
    console.log("error");
 });

My REST api returned 202 response (as seen on network tab) and on console I always see "Error" getting printed. Is there anything in ember which treats 202 as an error? if yes, how can it be fixed?




Aucun commentaire:

Enregistrer un commentaire