More, minor refactorings.