refactoring of the school repo