Commit 72d7dd08 authored by Quxl's avatar Quxl

x

parent df629a9f
......@@ -7,6 +7,7 @@ import java.util.Map;
import org.apache.solr.client.solrj.impl.HttpSolrClient;
import org.apache.solr.common.SolrInputDocument;
import com.egolm.common.StringUtil;
import com.egolm.search.config.XRException;
import com.google.common.collect.Lists;
......@@ -22,7 +23,7 @@ public abstract class AbstractSolrApi implements SolrApi {
SolrInputDocument solrInputDocument = new SolrInputDocument();
for (String key : map.keySet()) {
if (key != null && key.trim().length() > 0) {
solrInputDocument.addField(key, map.get(key));
solrInputDocument.addField(key, StringUtil.toString(map.get(key)));
}
}
docs.add(solrInputDocument);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment