refactored node repository