Socket
Socket
Sign inDemoInstall

@sanity/client

Package Overview
Dependencies
Maintainers
47
Versions
986
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sanity/client - npm Package Compare versions

Comparing version 6.15.10 to 6.15.11

7

dist/_chunks-es/stegaEncodeSourceMap.js

@@ -184,3 +184,3 @@ import { g as b } from "./browserMiddleware.js";

}
const filterDefault = ({ sourcePath, value }) => {
const filterDefault = ({ sourcePath, resultPath, value }) => {
if (isValidDate(value) || isValidURL(value))

@@ -191,3 +191,3 @@ return !1;

(path) => path === "meta" || path === "metadata" || path === "openGraph" || path === "seo"
) || typeof endPath == "string" && denylist.has(endPath));
) || hasTypeLike(sourcePath) || hasTypeLike(resultPath) || typeof endPath == "string" && denylist.has(endPath));
}, denylist = /* @__PURE__ */ new Set([

@@ -244,2 +244,5 @@ "color",

}
function hasTypeLike(path) {
return path.some((segment) => typeof segment == "string" && segment.match(/type/i) !== null);
}
const TRUNCATE_LENGTH = 20;

@@ -246,0 +249,0 @@ function stegaEncodeSourceMap(result, resultSourceMap, config) {

{
"name": "@sanity/client",
"version": "6.15.10",
"version": "6.15.11",
"description": "Client for retrieving, creating and patching data from Sanity.io",

@@ -5,0 +5,0 @@ "keywords": [

@@ -1,4 +0,4 @@

import type {FilterDefault} from './types'
import type {ContentSourceMapParsedPath, FilterDefault} from './types'
export const filterDefault: FilterDefault = ({sourcePath, value}) => {
export const filterDefault: FilterDefault = ({sourcePath, resultPath, value}) => {
// Skips encoding on URL or Date strings, similar to the `skip: 'auto'` parameter in vercelStegaCombine()

@@ -53,2 +53,8 @@ if (isValidDate(value) || isValidURL(value)) {

// If the sourcePath or resultPath contains something that sounds like a type, like iconType, we skip encoding, as it's most
// of the time used for logic that breaks if it contains stega characters
if (hasTypeLike(sourcePath) || hasTypeLike(resultPath)) {
return false
}
// Finally, we ignore a bunch of paths that are typically used for page building

@@ -115,1 +121,5 @@ if (typeof endPath === 'string' && denylist.has(endPath)) {

}
function hasTypeLike(path: ContentSourceMapParsedPath): boolean {
return path.some((segment) => typeof segment === 'string' && segment.match(/type/i) !== null)
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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