Fixed a number of things