Initial commit
This commit is contained in:
6
node_modules/validator/es/lib/isMongoId.js
generated
vendored
Normal file
6
node_modules/validator/es/lib/isMongoId.js
generated
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
import assertString from './util/assertString';
|
||||
import isHexadecimal from './isHexadecimal';
|
||||
export default function isMongoId(str) {
|
||||
assertString(str);
|
||||
return isHexadecimal(str) && str.length === 24;
|
||||
}
|
||||
Reference in New Issue
Block a user