From 00aa562b2f05a3e5198c8fef1be6e55bcb7e334a Mon Sep 17 00:00:00 2001 From: Georgia Hong Date: Wed, 18 Dec 2019 13:59:11 -0500 Subject: [PATCH] blobs: Stat method bug fix The stat method has a typo/bug, it return nil instead of err. This PR fixes it. Release note: None --- pkg/storage/cloud/external_storage.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/storage/cloud/external_storage.go b/pkg/storage/cloud/external_storage.go index 49059545b008..db8975a8b13a 100644 --- a/pkg/storage/cloud/external_storage.go +++ b/pkg/storage/cloud/external_storage.go @@ -396,7 +396,7 @@ func (l *localFileStorage) Delete(ctx context.Context, basename string) error { func (l *localFileStorage) Size(ctx context.Context, basename string) (int64, error) { stat, err := l.blobClient.Stat(ctx, joinRelativePath(l.base, basename)) if err != nil { - return 0, nil + return 0, err } return stat.Filesize, nil }