read()) !== null) { $written += \strlen($chunk); yield $destination->write($chunk); } return $written; }); }