changed chat's username generation to be done only once for all channels instead of for each
fix merge errors with chat branch