src refactor