Skip to content

Commit 80d3792

Browse files
committed
resolve the ai comment
1 parent a43310a commit 80d3792

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

google/cloud/storage/internal/grpc/object_read_source.cc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ GrpcObjectReadSource::GrpcObjectReadSource(
3131
std::shared_ptr<storage::internal::HashFunction> hash_function)
3232
: timer_source_(std::move(timer_source)),
3333
stream_(std::move(stream)),
34-
hash_function_(std::move(hash_function)) {}
34+
hash_function_(hash_function
35+
? std::move(hash_function)
36+
: storage::internal::CreateNullHashFunction()) {}
3537

3638
StatusOr<storage::internal::HttpResponse> GrpcObjectReadSource::Close() {
3739
if (stream_) stream_ = nullptr;

0 commit comments

Comments
 (0)