Move basename function from filesend to misc
Added callback to notify the new file in the groupchat