fixed a bug and removed redundant files