SHARE
TWEET

Untitled

a guest May 19th, 2019 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. async function b () {
  2.     console.log('done with func b');
  3. }
  4.  
  5. async function a() {
  6.         try {
  7.             throw 'this is the return message'
  8.     } catch (e) {
  9.             return e;
  10.     } finally {
  11.             await b();
  12.     }
  13. }
  14.  
  15. a().then(msg => {
  16.     console.log('done with func a');
  17.     console.log("return Msg:",msg)
  18. })
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top