suitest-js-api
Advanced tools
Comparing version 3.12.1 to 3.12.2
@@ -18,3 +18,3 @@ const {makeModifierComposer} = require('../utils/makeComposer'); | ||
acceptModalMessage: validate( | ||
validators.NON_EMPTY_STRING_OR_NUll, | ||
validators.STRING_OR_NULL, | ||
message, | ||
@@ -21,0 +21,0 @@ invalidInputMessage('acceptModal', 'Message value'), |
@@ -10,3 +10,3 @@ const validationKeys = { | ||
NON_EMPTY_STRING_OR_UNDEFINED: Symbol('nonEmptyStringOrUndefined'), | ||
NON_EMPTY_STRING_OR_NUll: Symbol('nonEmptyStringOrNull'), | ||
STRING_OR_NULL: Symbol('stringOrNull'), | ||
ARRAY_OF_BUTTONS: Symbol('arrayOfButtons'), | ||
@@ -13,0 +13,0 @@ ELEMENT_PROP_TYPE: Symbol('elementPropType'), |
@@ -222,8 +222,8 @@ const Ajv = require('ajv'); | ||
const validateNonEmptyStringOrNull = (val, name) => { | ||
if (typeof val === 'string' && val.length || val === null) { | ||
const validateStringOrNull = (val, name) => { | ||
if (typeof val === 'string' || val === null) { | ||
return val; | ||
} | ||
throwError(name + ' should be non empty string or null'); | ||
throwError(name + ' should be a string or null'); | ||
}; | ||
@@ -325,3 +325,3 @@ | ||
validateNonEmptyStringOrUndefined, | ||
validateNonEmptyStringOrNull, | ||
validateStringOrNull, | ||
validateUntilConditionChain, | ||
@@ -328,0 +328,0 @@ validateRepoProps, |
@@ -26,4 +26,4 @@ const validationKeys = require('../../lib/constants/validationKeys'); | ||
}, | ||
[validationKeys.NON_EMPTY_STRING_OR_NUll]: (value, text) => { | ||
return validators.validateNonEmptyStringOrNull(value, text); | ||
[validationKeys.STRING_OR_NULL]: (value, text) => { | ||
return validators.validateStringOrNull(value, text); | ||
}, | ||
@@ -30,0 +30,0 @@ [validationKeys.ARRAY_OF_BUTTONS]: (value, text) => { |
{ | ||
"name": "suitest-js-api", | ||
"version": "3.12.1", | ||
"version": "3.12.2", | ||
"main": "index.js", | ||
@@ -5,0 +5,0 @@ "repository": "git@github.com:SuitestAutomation/suitest-js-api.git", |
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
420546