Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

11
  • 1
    Thats the best idea ever, I'm doing that all the time, thats what await is good for! Commented Oct 4, 2018 at 20:20
  • 1
    Just be to sure to handle promise (await) rejections... Commented Oct 4, 2018 at 20:21
  • @CodyG. and how does one handle promise (await) rejections? Commented Oct 4, 2018 at 20:22
  • i've done it: var pw=this.parseHex(await this.derive(password)); Commented Oct 4, 2018 at 20:22
  • 1
    Hmmm. New question: what happens when you call something like foo(await bar1(), await bar2()) ? I assume bar2 waits until bar1 but I'm too lazy to try and have never used that syntax Commented Oct 4, 2018 at 20:25