Refactoring
Fix issue #38