Fixed some formatting issues. Cleaned up some if/else structures.