cleaned up some logic. all future commits should be working commits