fix private on class methods + tiny refactorings