Skip to content

Commit 98ad33c

Browse files
committed
[1.4.4] Fixed isRequired validator
1 parent 4a3844c commit 98ad33c

File tree

6 files changed

+14
-7
lines changed

6 files changed

+14
-7
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## 1.4.4
2+
3+
### Fixed
4+
5+
- `isRequired` validator
6+
17
## 1.4.3
28

39
### Added

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ See demo at [https://detools.github.io/vue-form](https://detools.github.io/vue-f
7878

7979
## Changelog
8080

81+
- [1.4.4](/CHANGELOG.md#144)
8182
- [1.4.3](/CHANGELOG.md#143)
8283
- [1.4.2](/CHANGELOG.md#142)
8384
- [1.4.1](/CHANGELOG.md#141)

VueForm/validations/isRequired.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import isEmpty from 'lodash/isEmpty'
1+
import isNil from 'lodash/isNil'
22
import startCase from 'lodash/startCase'
33

44
export default function isRequired(customMessage) {
55
return (value, name) =>
6-
isEmpty(value) ? customMessage || `${startCase(name)} is required` : undefined
6+
isNil(value) ? customMessage || `${startCase(name)} is required` : undefined
77
}

docs/bundle.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/vendors~main.bundle.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@detools/vue-form",
3-
"version": "1.4.3",
3+
"version": "1.4.4",
44
"description": "Vue Form component on hooks",
55
"main": "VueForm/index.js",
66
"scripts": {

0 commit comments

Comments
 (0)