Fix async demo
A couple of simple optimizations