From 93da8a9cde7af69c0ac21694266c5d238cbd6d70 Mon Sep 17 00:00:00 2001 From: Arie Ozarov Date: Tue, 17 Nov 2015 19:39:46 -0800 Subject: [PATCH] fix readmes for storage --- README.md | 3 +-- gcloud-java-storage/README.md | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index bba06a7e60d4..03bf2e69f915 100644 --- a/README.md +++ b/README.md @@ -164,8 +164,7 @@ import com.google.gcloud.storage.StorageOptions; import java.nio.ByteBuffer; import java.nio.channels.WritableByteChannel; -StorageOptions options = StorageOptions.builder().projectId("project").build(); -Storage storage = options.service(); +Storage storage = StorageOptions.defaultInstance().service(); BlobId blobId = BlobId.of("bucket", "blob_name"); Blob blob = Blob.load(storage, blobId); if (blob == null) { diff --git a/gcloud-java-storage/README.md b/gcloud-java-storage/README.md index 8b19484dd14d..0302439a4314 100644 --- a/gcloud-java-storage/README.md +++ b/gcloud-java-storage/README.md @@ -68,7 +68,7 @@ import com.google.gcloud.storage.StorageOptions; import java.nio.ByteBuffer; import java.nio.channels.WritableByteChannel; -Storage storage = StorageOptions.getDefaultInstance().service(); +Storage storage = StorageOptions.defaultInstance().service(); Blob blob = new Blob(storage, "bucket", "blob_name"); if (!blob.exists()) { storage2.create(blob.info(), "Hello, Cloud Storage!".getBytes(UTF_8));