react-hook-form 7.44.0-rc.4 → 7.44.0-rc.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.mjs +1 -1
- package/dist/index.esm.mjs.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.mjs
CHANGED
@@ -879,7 +879,7 @@ var validateField = async (field, formValues, validateAllFieldCriteria, shouldUs
|
|
879
879
|
}
|
880
880
|
}
|
881
881
|
}
|
882
|
-
if (pattern && isString(inputValue)) {
|
882
|
+
if (pattern && !isEmpty && isString(inputValue)) {
|
883
883
|
const { value: patternValue, message } = getValueAndMessage(pattern);
|
884
884
|
if (isRegex(patternValue) && !inputValue.match(patternValue)) {
|
885
885
|
error[name] = {
|