Minor edits to cleanup the code a bit