changed buddypress core file to work with chat