Changes to fix all the bugs that were prevalent