Cleaned a lot of code.