Changed code to match my code style.