emit 'register' event
Merge pull request #3 from nathan7/master

emit 'register' event