refactoring
streams fix