-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
Labels:
-
Environment:
*Location*: http://docs.mongodb.org/manual/reference/method/db.addUser/
*User-Agent*: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.72 Safari/537.36
*Referrer*: https://www.google.com/
*Screen Resolution*: 1440 x 900
*repo*: docs
*source*: reference/method/db.addUser
*Location*: http://docs.mongodb.org/manual/reference/method/db.addUser/ *User-Agent*: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.72 Safari/537.36 *Referrer*: https://www.google.com/ *Screen Resolution*: 1440 x 900 *repo*: docs *source*: reference/method/db.addUser
The documentation for addUser 2.2.2 readOnly property is incorrect. It is listed as db.addUser("username","password",
{"readOnly":false}) but it should be db.addUser("username","password",false);
If you use the format the documentation suggests it creates a user with a readOnly field that is a document not a boolean and you can't write from this user.