Added stream.Duplex check for sink