var mongoose = require('mongoose');

module.exports.finderForProperty = function(field, props) {
    if (props === undefined) {
        props = {};
    }

    var isFindOne = props['findOne'] === true;
    var caseInsensitive = props['caseInsensitive'] === true;

    return function(value, cb) {
        var lookupHash = {};
        lookupHash[field] = caseInsensitive ? new RegExp('^' + value + '$', 'i') : value;

        if(isFindOne) {
            this.findOne(lookupHash, cb);
        } else {
            this.find(lookupHash, cb);
        }
    };
};

module.exports.pushOntoProperty = function(field, props) {
  if (props === undefined) {
    props = {};
  }

  var isFindOne = props['findOne'] === true;
  var caseInsensitive = props['caseInsensitive'] === true;

  return function(value, cb) {
    var lookupHash = {};
    lookupHash[field] = caseInsensitive ? new RegExp('^' + value + '$', 'i') : value;

    if (isFindOne) {
      //
    } else {
      //
    }
  }
}

@@ -933,26 +933,29 @@
 ne) %7B%0A      
-//
+this.
 %0A    %7D else 
@@ -966,10 +966,13 @@
     
-//
+this.
 %0A   

Revert "SYNTAX ERROR SORRY EVERYONE"