Fixed some errors and cleaned up much!