Closed vivi173 closed 3 years ago
Thanks for reporting. It works for me either with or without '' on Ubuntu 20.04. What platform are you working on?
Hi Hamish, I'm working on windows 10, version 1909.
Thanks very much! I have removed the offending text :-). FYI only double quotes do work.
Request type
Details
In Express Tutorial Part 3: Using a Database..., there's a little issue in the section 'Testing - create some items'. Step 3 Run the script using node in your command prompt, passing in the URL of your MongoDB database (the same one you replaced the insert_your_database_url_here placeholder with, inside app.js earlier): Be sure to pass it as a string by wrapping it with ' '.
The URL should not be wrapped by ' ' in order for the query to run successfully on the command prompt. Enclosing it in ' ' throws an error.
https://developer.mozilla.org/en-US/docs/Learn/Server-side/Express_Nodejs/mongoose