Use stream correctly. Closes #3.