Fixed a lot of dumb errors.