LearnBoost/mongoose — pull request #1509 by bitmage (2013-05-23 23:20:30+00:00)
Title: Added a clearer error message

The previous error message stated "A non-capped collection exists with that name."

The driver has the name available in this context, so there's reason not to report it. It makes troubleshooting easier.

Also, for anyone that's interested, I traced the problem I was having down to a conflict with Sugar. This code:

```javascript
if (!self.opts.capped.size) {
```

Will incorrectly detect all your collections as capped if you have included the library Sugar and performed Object.extend(). Not mongoose's problem of course, but keep an eye out for it if you're an application developer doing this. See this thread for a solution:

https://github.com/andrewplummer/Sugar/issues/248#issuecomment-16199570