Removed a bunch of unnecessary files and duplicate code