Defcon27 / Autorizz-Car-Dealership-System-using-NodeJS-Express-MongoDB

It is a web-based DMS application that facilitates the management of automobile dealership increasing its efficiency and makes management much easier.
https://autorizz.herokuapp.com/electric/
MIT License
64 stars 44 forks source link

MongoDB Data table doesnt get created #6

Closed ghost closed 3 years ago

ghost commented 3 years ago

(node:3565839) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'password' of null at /var/lib/pterodactyl/volumes/2d9ecc6e-52f3-4036-b806-37d90b13e84b/routes/admin.js:50:22 at process._tickCallback (internal/process/next_tick.js:68:7) (node:3565839) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1) (node:3565839) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. ^C

Defcon27 commented 3 years ago

Are you sure , you created a collection named user and added a user in your mongodb database, for example

{
  "_id": {
    "$oid": "5e7ed8a9356323b52740ece6"
  },
  "userID": "admin",
  "password": "admin"
}
ghost commented 3 years ago

I didn't do that. You should try adding that to the readme. I will try it today! Thanks

Defcon27 commented 3 years ago

I didn't do that. You should try adding that to the readme. I will try it today! Thanks

cool thanks for visiting this repo

AliKhyar commented 2 years ago

@Defcon27 trying to upload data to mongo, returns MongoServerError: _id fields may not contain '$'-prefixed fields: $oid is not valid for storage. The data uploaded when the dollar sign is removed, but a 404 error occurs in booknow route, which I don't know if it's resulted by removing the dollar sign in oid!