Added map function using new events
Removed obsolete code
Uncommented 'push!'
Converted merge function to new system