Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
format
  • Loading branch information
thiyaguk09 committed Dec 13, 2024
1 parent e8d65ae commit 2d60a9b
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions samples/getSoftDeletedBucket.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

function main(bucketName = 'my-bucket', generation = 123456789) {
// [START storage_get_softDeleted_bucket]
// [START storage_get_soft_deleted_bucket]
/**
* TODO(developer): Uncomment the following lines before running the sample.
*/
Expand Down Expand Up @@ -46,7 +46,7 @@ function main(bucketName = 'my-bucket', generation = 123456789) {
}

getSoftDeletedBucket().catch(console.error);
// [END storage_get_softDeleted_bucket]
// [END storage_get_soft_deleted_bucket]
}

main(...process.argv.slice(2));
4 changes: 2 additions & 2 deletions samples/listSoftDeletedBucket.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

function main() {
// [START storage_list_buckets]
// [START storage_list_soft_deleted_buckets]
// Imports the Google Cloud client library
const {Storage} = require('@google-cloud/storage');

Expand All @@ -36,7 +36,7 @@ function main() {
}

listSoftDeletedBuckets().catch(console.error);
// [END storage_list_buckets]
// [END storage_list_soft_deleted_buckets]
}

main(...process.argv.slice(2));
10 changes: 5 additions & 5 deletions samples/restoreSoftDeletedBucket.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@
* limitations under the License.
*/

function main(bucketName = 'my-bucket', generation = 1) {
// [START storage_restore_bucket]
function main(bucketName = 'my-bucket', generation = 123456789) {
// [START storage_restore_soft_deleted_bucket]
/**
* TODO(developer): Uncomment the following lines before running the sample.
*/
// The ID of your GCS bucket
// const bucketName = 'your-unique-bucket-name';

// The version of your GCS bucket
// const generation = 'your-unique-bucket-generation-no';
// The generation of the bucket to restore
// const generation = 123456789;

// Imports the Google Cloud client library
const {Storage} = require('@google-cloud/storage');
Expand All @@ -42,7 +42,7 @@ function main(bucketName = 'my-bucket', generation = 1) {
}

restoreSoftDeletedBucket().catch(console.error);
// [END storage_restore_bucket]
// [END storage_restore_soft_deleted_bucket]
}

main(...process.argv.slice(2));
2 changes: 1 addition & 1 deletion system-test/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -794,7 +794,7 @@ describe('storage', function () {
describe('buckets', () => {
let bucket: Bucket;
const SOFT_DELETE_RETENTION_SECONDS = 7 * 24 * 60 * 60; //7 days in seconds;
let generation = 123;
let generation = 123456789;

before(async () => {
bucket = storage.bucket(generateName());
Expand Down
4 changes: 2 additions & 2 deletions test/bucket.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2436,13 +2436,13 @@ describe('Bucket', () => {
assert.deepStrictEqual(reqOpts, {
method: 'POST',
uri: '/restore',
qs: {generation: 123},
qs: {generation: 123456789},
});
assert.strictEqual(callback_, undefined);
return [];
};

await bucket.restore({generation: 123});
await bucket.restore({generation: 123456789});
});
});

Expand Down

0 comments on commit 2d60a9b

Please sign in to comment.