Cleaned up code

Yay for efficiency :D