Issue #76: A bit more refactoring