Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

mongoose check if string is objectid

new ObjectId('timtamtomted'); //616273656e6365576f726b73
new ObjectId('537eed02ed345b2e039652d2') //537eed02ed345b2e039652d2
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #mongoose #check #string #objectid
ADD COMMENT
Topic
Name
9+3 =