Cleaned up some code for improved readability.