Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

238
Views
Argument passed in must be a string of 12 bytes or a string of 24 hex characters or an integer

I am new to coding so I can not understand and solve this problem if you want please help me.

C:\projects\assignment-11\spice-warehouse-server\node_modules\bson\lib\error.js:41 var _this = _super.call(this, message) || this; ^

BSONTypeError: Argument passed in must be a string of 12 bytes or a string of 24 hex characters or an integer at new BSONTypeError (C:\projects\assignment-11\spice-warehouse-server\node_modules\bson\lib\error.js:41:28) at new ObjectId (C:\projects\assignment-11\spice-warehouse-server\node_modules\bson\lib\objectid.js:66:23) at ObjectId (C:\projects\assignment-11\spice-warehouse-server\node_modules\bson\lib\objectid.js:26:20) at C:\projects\assignment-11\spice-warehouse-server\index.js:38:33 at Layer.handle [as handle_request] (C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\layer.js:95:5) at next (C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\route.js:144:13) at Route.dispatch (C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\route.js:114:3) at Layer.handle [as handle_request] (C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\layer.js:95:5) at C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\index.js:286:22 at param (C:\projects\assignment-11\spice-warehouse-server\node_modules\express\lib\router\index.js:367:14) [nodemon] app crashed - waiting for file changes before starting...

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

Your problem may be related to express.js related, so if this is your problem then you first turn off your server pressing by ctrl + c then turn it on again, then you go to your UI and hit reload then it will work properly.

about 4 years ago · Juan Pablo Isaza Report

0

Your ID is not being sent. You can try this way:

const query = { _id: ObjectId('yourid') };
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!