adding const to messageevent data