Optimize the code and updated to 1.0.1