protected override IndexQueryResult RetrieveDocument(Document document, FieldsToFetch fieldsToFetch)
{
if (fieldsToFetch.IsProjection == false)
{
fieldsToFetch = fieldsToFetch.CloneWith(document.GetFields().OfType <Fieldable>().Select(x => x.Name()).ToArray());
}
fieldsToFetch.EnsureHasField(Raven.Abstractions.Data.Constants.ReduceKeyFieldName);
return(base.RetrieveDocument(document, fieldsToFetch));
}