Wrapped with modules API.
Fix afterCurrentEvent() -> nextTick()
Merge branch 'master' into dev