tightened up event stack fn, updated dist