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

apostrophe-caches-redis

Package Overview
Dependencies
Maintainers
14
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apostrophe-caches-redis - npm Package Compare versions

Comparing version 2.1.5 to 2.1.6

5

CHANGELOG.md
# Changelog
## 2.1.6 - 2023-02-17
- Fixed the `removeBadIndexMigration` migration to not cause an error due to the lack of collections when using redis. Thanks to [Felix](https://github.com/felixlberg).
- Changes method of closing the redis connection to use `quit()` in place of the soon to be deprecated `removeAllListeners()` and `destroy()` methods. Thanks to [Felix](https://github.com/felixlberg).
## 2.1.5 - 2023-02-01

@@ -4,0 +9,0 @@

20

index.js

@@ -13,5 +13,7 @@ // TODO:

construct: function(self, options) {
//The removeAllListeners and destroy methods were used in earlier versions of the redis to close a connection.
//However, in recent versions of the redis, the recommended method for closing a connection
//is to call the quit method on the Redis client instance.
self.on('apostrophe:destroy', 'closeRedisConnection', function() {
self.client.stream.removeAllListeners();
self.client.stream.destroy();
self.client.quit();
});

@@ -38,2 +40,16 @@ // Replace the apostrophe-caches implementation of getCollection in a bc way

// Override removeBadIndexMigration function, which is not needed since we are
// not using mongo collections
self.removeBadIndexMigration = function() {
self.on('apostrophe:modulesReady', 'addRemoveBadIndexMigration', function() {
try {
self.apos.migrations.add(self.__meta.name + '.removeBadIndex', async function() {
// remove the code that references the "indexes" property
});
} catch (error) {
console.error(error);
}
});
};
self.constructCache = function(name) {

@@ -40,0 +56,0 @@

2

package.json
{
"name": "apostrophe-caches-redis",
"version": "2.1.5",
"version": "2.1.6",
"description": "Redis-based cache for the Apostrophe CMS",

@@ -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