@medipass/utils 11.59.1-fix-date-picker-issues.0 → 11.59.1-fix-date-picker-issues.1
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/package.json +2 -2
- package/validate-form.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medipass/utils",
|
|
3
|
-
"version": "11.59.1-fix-date-picker-issues.
|
|
3
|
+
"version": "11.59.1-fix-date-picker-issues.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "index.js",
|
|
@@ -47,5 +47,5 @@
|
|
|
47
47
|
"redux-thunk": "^2.2.0",
|
|
48
48
|
"rimraf": "^2.6.2"
|
|
49
49
|
},
|
|
50
|
-
"gitHead": "
|
|
50
|
+
"gitHead": "bbf2af0b79eb1c6acb46952851a60e54d7c8e929"
|
|
51
51
|
}
|
package/validate-form.js
CHANGED
|
@@ -196,7 +196,7 @@ var isValidDate = function isValidDate(value) {
|
|
|
196
196
|
return !isValid(parse(value, 'dd/MM/yyyy', new Date())) ? 'Date is invalid' : undefined;
|
|
197
197
|
};
|
|
198
198
|
var isValidDateOrEmpty = function isValidDateOrEmpty(value) {
|
|
199
|
-
return
|
|
199
|
+
return value && isValid(parse(value)) ? undefined : 'Date is invalid';
|
|
200
200
|
};
|
|
201
201
|
var isValidUrlAsync = /*#__PURE__*/function () {
|
|
202
202
|
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(value) {
|