adding async function

When adding asynchronous function, call resolver.resolve when data is ready.

Use q.add(fn, name) to add fn to the queue, and restore its return value in q.data[name]