Skip to content

Instantly share code, notes, and snippets.

@drsm79
Created July 16, 2012 11:29
Show Gist options
  • Save drsm79/3122224 to your computer and use it in GitHub Desktop.
Save drsm79/3122224 to your computer and use it in GitHub Desktop.
function(doc){
index("default", doc._id);
if(doc.min_length){
index("min_length", doc.min_length, {"store": "yes"});
}
if(doc.diet){
index("diet", doc.diet, {"store": "yes"});
}
if (doc['class']){
index("class", doc.['class'], {"store": "yes"});
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment