Skip to content

Commit 8664cd6

Browse files
authored
Merge pull request #29 from divsbhalala/master
Update id-validator.js
2 parents aecb3f0 + 0778c42 commit 8664cd6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/id-validator.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,9 @@ function executeQuery (query, conditions, validateValue, respond) {
9696
}
9797
query.exec(function (err, count) {
9898
if (err) {
99-
return respond(err)
99+
return respond ? respond(err) : err
100100
}
101-
respond(count === validateValue)
101+
return respond ? respond(count === validateValue) : count === validateValue
102102
})
103103
}
104104

0 commit comments

Comments
 (0)