Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70432

Http post error handling

$
0
0

@mdline wrote:

Hello,

I switch off my internet connection and want to test which error code I got for my backend call and its always returns null.

this.http.post(URL, body, options)
       .subscribe(
         response => {
         console.log(response);
         },
         error => {
           console.log(error);

         }
       );

But I want to get the http status codes.

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70432

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>