fixing bugs in various things
fixed more namespace bugs