Fix bug in def method and change name of some module directory