Skip to content

Commit ff8130f

Browse files
author
Frank Natividad
committed
Use Field Selector and remove unused import
1 parent 454eaa2 commit ff8130f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

google-cloud-examples/src/main/java/com/google/cloud/examples/storage/snippets/StorageSnippets.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@
6666
import java.net.URL;
6767
import java.nio.ByteBuffer;
6868
import java.nio.file.Path;
69-
import java.nio.file.Paths;
7069
import java.util.HashMap;
7170
import java.util.LinkedList;
7271
import java.util.List;
@@ -1101,7 +1100,8 @@ public Bucket getRequesterPaysStatus(String bucketName) throws StorageException
11011100
// The name of the bucket to retrieve requester-pays status, eg. "my-bucket"
11021101
// String bucketName = "my-bucket"
11031102
// Retrieve the bucket, throws StorageException on failure
1104-
Bucket bucket = storage.get(bucketName);
1103+
Bucket bucket = storage.get(bucketName,
1104+
Storage.BucketGetOption.fields(BucketField.BILLING));
11051105

11061106
System.out.println("Requester pays status : " + bucket.requesterPays());
11071107
// [END get_requester_pays_status]

0 commit comments

Comments
 (0)