cleared up some minor formatting issues and redundant code