changed textual references to use stream