clean up codes and removed unused classes