More refactoring of the SourceCollector