Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Not op, I think what he means is the session, even when already failed once, can still be used (without error) in the next operation without being invalidated.

Without promise.all, I think it can be replicated like this:

    try{
      await someOp(session);
    catch { }
    await someOtherOp(session);
He expected what the session to be invalidated during someOtherOp.


That is correct and what I meant. Thanks, and there doesn't have to be a `try/catch` because it is possible to "fork" control with promises.

They implemented a "disposer" incorrectly (I added this to several other libraries and made a Q&A about it here https://stackoverflow.com/questions/28915677/what-is-the-pro... )




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: