fix of refactoring bug