Merge pull request #14 from idxxx23/develop

repair some bugs + simplify