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

ssr-cache

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ssr-cache - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

16

index.js

@@ -30,4 +30,4 @@ 'use strict';

}
this.cache.get(this.prefix+key, function (err, value) {
err || !value ? reject(err) : resolve(value)
this.cache.get(this.prefix+key, function (err, val) {
err ? reject('memcached is not runing!') : resolve(val)
})

@@ -50,4 +50,4 @@ })

// memcached return callback value
this.cache.set(this.prefix+key, value, {expires}, function (err, value) {
err || !value ? reject(err) : resolve(value)
this.cache.set(this.prefix+key, value, {expires}, function (err, val) {
err ? resolve(value) : resolve(val)
})

@@ -71,11 +71,5 @@ })

Cache.prototype.memcached = () => {
try {
return memcached.Client.create();
} catch (e) {
console.log('memcached client does not exist!, switched to lru cache')
this.type = 'lru'
return this.lru()
}
};
module.exports = Cache;
module.exports = Cache;
{
"name": "ssr-cache",
"version": "0.0.4",
"version": "0.0.5",
"description": "Api Serve-Side Cache Wrapper for Lru and Memcached",

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

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