This entire functions indentation is waaaaaaaay off.