Removed old dependencies, cleaned up some code