title: mongoose, trying to find one object by a value
body: <p>What I'm trying to accomplish here is to find one object by a value, and then adding that object to another objects property.</p>
  
  <p><strong><em>Code</em></strong></p>
  
  <p>q = {
      _id: Schema.Types.ObjectId,
      category: QuestionCategory,
      question: String,
      name: String,
  };</p>
  
  <pre><code>QuestionCategory.findOne().sort({ category: "ExampleCategory" }).exec((err, doc) =&gt; {
      if(err)
      {
          return err
      }
      q.category = doc;
  })
  </code></pre>
  
  <p>error: </p>
  
  <pre><code>throw new TypeError('Invalid sort value: {' + field + ': ' + value + ' }');
      ^
  
  TypeError: Invalid sort value: {category: ExampleCategory }
  </code></pre>
  
  <p>I've also tried without the .sort and write the filter inside findOne, but didn't work either</p>
  
  <p>The Schema</p>
  
  <pre><code>const QuestionCategorySchema= new Schema({
      _id: Schema.Types.ObjectId,
      category: String,
      icon: String,
      order: Number
  }, { collection: 'QuestionCategory' });
  </code></pre>