Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

google-cloud-bucket

Package Overview
Dependencies
Maintainers
1
Versions
68
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

google-cloud-bucket - npm Package Compare versions

Comparing version 0.11.2 to 0.11.3

10

CHANGELOG.md

@@ -5,2 +5,12 @@ # Change Log

<a name="0.11.3"></a>
## [0.11.3](https://github.com/nicolasdao/google-cloud-bucket/compare/v0.11.2...v0.11.3) (2019-02-19)
### Bug Fixes
* Fail to add non truthy value to a file ([c16fe07](https://github.com/nicolasdao/google-cloud-bucket/commit/c16fe07))
<a name="0.11.2"></a>

@@ -7,0 +17,0 @@ ## [0.11.2](https://github.com/nicolasdao/google-cloud-bucket/compare/v0.11.1...v0.11.2) (2019-02-12)

20

index.js

@@ -36,2 +36,20 @@ /**

const _retryPutFn = (fn, options={}) => retry(
fn,
res => {
//console.log(`STATUS: ${res.status}`)
if (res && res.status == 429) {
//console.log('TOO MANY UPDATES')
return false
} else
return true
},
{ ignoreFailure: true, retryInterval: [800, 2000], timeOut: options.timeout || 10000 })
.catch(e => {
if (options.retryCatch)
return options.retryCatch(e)
else
throw e
})
const _throwHttpErrorIfBadStatus = res => Promise.resolve(null).then(() => {

@@ -85,3 +103,3 @@ if (res && res.status && res.status >= 400) {

const putObject = (object, filePath, options) => getToken(auth).then(token => _retryFn(() => gcp.insert(object, filePath, token, options), options))
const putObject = (object, filePath, options) => getToken(auth).then(token => _retryPutFn(() => gcp.insert(object, filePath, token, options), options))
.then(_throwHttpErrorIfBadStatus)

@@ -88,0 +106,0 @@ .then(({ data }) => data)

2

package.json
{
"name": "google-cloud-bucket",
"version": "0.11.2",
"version": "0.11.3",
"description": "Nodejs package to add objects to a Google Cloud Bucket.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -23,3 +23,3 @@ /**

const _validateRequiredParams = (params={}) => Object.keys(params).forEach(p => {
if (!params[p])
if (params[p] === null || params[p] === undefined)
throw new Error(`Parameter '${p}' is required.`)

@@ -26,0 +26,0 @@ })

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc