fix username not always being defined at a certain point.