🚨 Active Supply Chain Attack:node-ipc Package Compromised.Learn More
Socket
Book a DemoSign in
Socket

@vercel/functions

Package Overview
Dependencies
Maintainers
2
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vercel/functions - npm Package Compare versions

Comparing version
3.4.2
to
3.4.3
+2
-21
cache/index.js

@@ -40,17 +40,2 @@ "use strict";

const defaultNamespaceSeparator = "$";
function encodeTags(tags) {
return tags.map(encodeURIComponent);
}
function encodeTag(tag) {
return Array.isArray(tag) ? encodeTags(tag) : encodeURIComponent(tag);
}
function encodeOptions(options) {
if (!options) {
return void 0;
}
if (options.tags && options.tags.length > 0) {
return { ...options, tags: encodeTags(options.tags) };
}
return options;
}
let inMemoryCacheInstance = null;

@@ -90,7 +75,3 @@ let buildCacheInstance = null;

set: (key, value, options) => {
const encodedOptions = encodeOptions(options);
if (encodedOptions) {
return resolveCache().set(makeKey(key), value, encodedOptions);
}
return resolveCache().set(makeKey(key), value);
return resolveCache().set(makeKey(key), value, options);
},

@@ -101,3 +82,3 @@ delete: (key) => {

expireTag: (tag) => {
return resolveCache().expireTag(encodeTag(tag));
return resolveCache().expireTag(tag);
}

@@ -104,0 +85,0 @@ };

+6
-0
# @vercel/functions
## 3.4.3
### Patch Changes
- [functions] Revert "[functions] URL encode cache tags" ([#15213](https://github.com/vercel/vercel/pull/15213))
## 3.4.2

@@ -4,0 +10,0 @@

@@ -264,3 +264,3 @@ # Module: index

[packages/functions/src/cache/index.ts:55](https://github.com/vercel/vercel/blob/main/packages/functions/src/cache/index.ts#L55)
[packages/functions/src/cache/index.ts:33](https://github.com/vercel/vercel/blob/main/packages/functions/src/cache/index.ts#L33)

@@ -267,0 +267,0 @@ ---

@@ -33,3 +33,3 @@ {

},
"version": "3.4.2",
"version": "3.4.3",
"repository": {

@@ -36,0 +36,0 @@ "directory": "packages/functions",