fixed a bunch of stuff