title: Mongoose update document with conditions
body: <p>I need to unset mongo field which is ObjectId and refers to another schema if this ID is Id of a current user and this field is set. In other case, if this field is unset, current user ID should be set. If the field is set and ObjectID doen't match the current user ID's mongo should return existing document but without changes apllied to the ObjectID field.</p>
  
  <p>Right now I find entry by ID and then check cases in my JS code. Then I perform another query in order to update the document. But I think that this could be done by mongo in one query.</p>
  
  <p>I'm using mongoose in my nodeJS</p>