You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following check causes authentication with a blank password to be skipped resulting in a 'Error setting TTL index on collection' error when later trying to ensure the indexes exist. This occurs on mongodb configurations that require strict authentication. This was noticed in a dev environment where the password used was just the empty string ('').
It might also be useful to print out the actual error that occurs when ensureIndex fails as we first thought this was related to the race condition described in other issues (#65, #70, #80).
The following check causes authentication with a blank password to be skipped resulting in a 'Error setting TTL index on collection' error when later trying to ensure the indexes exist. This occurs on mongodb configurations that require strict authentication. This was noticed in a dev environment where the password used was just the empty string (
''
).https://github.com/kcbanner/connect-mongo/blob/master/lib/connect-mongo.js#L181
Perhaps the fix is simply:
But I'm not sure how much more comprehensive that check needs to be in this lib.
The text was updated successfully, but these errors were encountered: