fix #74, may has some problems

cause havn't tested enough