Some minor fixes and stuff