title: Can't connect to MongoDB via flask_pymongo
body: <p>I just encountered a problem while playing with <code>Flask</code> and <code>MongoDB</code>. Here are scenarios</p>
  
  <blockquote>
    <p>With Authorization Enabled</p>
  </blockquote>
  
  <p>If I use <code>PyMongo()</code> from <code>flask_pymongo</code> with <code>mongo = PyMongo(app)</code> pattern, I just get <code>Authorization Errors</code>. While I am able to successfully retrieve database via <code>MonogoClient()</code> from <code>pymongo</code> using same connection string.</p>
  
  <blockquote>
    <p>Without Authorization Enabled</p>
  </blockquote>
  
  <p>If I use <code>flask_pymongo</code>, no errors. But I am not getting any data either. For example, <code>mongo.db.collection_names()</code> just returns empty array.  With <code>MongoClient()</code>, the same operation was successful.</p>
  
  <blockquote>
    <p>I am using:</p>
  </blockquote>
  
  <ul>
  <li>python = 3.6.3</li>
  <li>flask = 0.12.2</li>
  <li>flask_pymongo = 0.5.1</li>
  <li>pymongo = 3.5.1</li>
  </ul>
  
  <p>Thanks in Advance</p>