Merge pull request #483 from yushijinhun/working

Fix bugs