Reorganized and implemented a couple of features