New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

cacheable-response

Package Overview
Dependencies
Maintainers
1
Versions
111
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cacheable-response - npm Package Compare versions

Comparing version 1.3.0 to 1.3.1

5

CHANGELOG.md

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

<a name="1.3.1"></a>
## [1.3.1](https://github.com/Kikobeats/cacheable-response/compare/v1.3.0...v1.3.1) (2019-03-29)
<a name="1.3.0"></a>

@@ -7,0 +12,0 @@ # [1.3.0](https://github.com/Kikobeats/cacheable-response/compare/v1.2.1...v1.3.0) (2019-03-28)

5

index.js

@@ -68,8 +68,9 @@ 'use strict'

const hasData = cachedData !== undefined
const isHit = !hasForce && hasData
const cachedResult =
compress && hasData ? JSON.parse(await brotliDecompress(cachedData)) : cachedData
const isHit = !hasForce && hasData
const { etag: cachedEtag, ttl = defaultTtl, createdAt = Date.now(), data, ...props } = isHit
? cachedResult || {}
? cachedResult
: await get({ req, res, ...opts })

@@ -76,0 +77,0 @@

2

package.json

@@ -5,3 +5,3 @@ {

"homepage": "https://nicedoc.io/Kikobeats/cacheable-response",
"version": "1.3.0",
"version": "1.3.1",
"main": "index.js",

@@ -8,0 +8,0 @@ "author": {

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