@shopify/theme-check-node
Advanced tools
Comparing version 1.17.0 to 1.18.0
@@ -9,7 +9,7 @@ "use strict"; | ||
(0, node_assert_1.strict)(settings, `Unexpected missing settings for ${check.meta.code} in validateConfig call`); | ||
validateSettings(check.meta.schema, settings, true); | ||
validateSettings(check.meta.code, check.meta.schema, settings, true); | ||
} | ||
} | ||
exports.validateConfig = validateConfig; | ||
function validateSettings(schema, settings, isTopLevel) { | ||
function validateSettings(checkCode, schema, settings, isTopLevel) { | ||
for (const key in schema) { | ||
@@ -23,3 +23,3 @@ const schemaProp = schema[key]; | ||
} | ||
validateSuperfluousSettings(schema, settings); | ||
validateSuperfluousSettings(checkCode, schema, settings); | ||
} | ||
@@ -32,7 +32,7 @@ function validateCommonCheckSettings(settings) { | ||
} | ||
function validateSuperfluousSettings(schema, settings) { | ||
function validateSuperfluousSettings(checkCode, schema, settings) { | ||
const commonCheckSettingsKeys = ['enabled', 'severity', 'ignore']; | ||
for (const key in settings) { | ||
if (!(key in schema) && !commonCheckSettingsKeys.includes(key)) { | ||
node_assert_1.strict.fail(`Unexpected setting: ${key}`); | ||
console.error(`Unexpected setting: ${key} for check ${checkCode} found in configuration`); | ||
} | ||
@@ -39,0 +39,0 @@ } |
{ | ||
"name": "@shopify/theme-check-node", | ||
"version": "1.17.0", | ||
"version": "1.18.0", | ||
"main": "dist/index.js", | ||
@@ -28,4 +28,4 @@ "types": "dist/index.d.ts", | ||
"dependencies": { | ||
"@shopify/theme-check-common": "1.17.0", | ||
"@shopify/theme-check-docs-updater": "1.17.0", | ||
"@shopify/theme-check-common": "1.18.0", | ||
"@shopify/theme-check-docs-updater": "1.18.0", | ||
"glob": "^8.0.3", | ||
@@ -32,0 +32,0 @@ "yaml": "^2.3.0" |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
46164
+ Added@shopify/theme-check-common@1.18.0(transitive)
+ Added@shopify/theme-check-docs-updater@1.18.0(transitive)
- Removed@shopify/theme-check-common@1.17.0(transitive)
- Removed@shopify/theme-check-docs-updater@1.17.0(transitive)