add error handling to return stream