Dat refactor right before deadline.. mmmmmmhm so much fun.