Fix xml escape

This commit is contained in:
Andrea Cavalli 2023-06-11 00:10:46 +02:00
parent dec229ac78
commit e9c765f7da

View File

@ -599,7 +599,7 @@ public class QueryParser {
ensureValidField(solrTextQuery.field());
out.append(solrTextQuery.field());
out.append(":");
out.append("\"").append(escapeQueryStringValue(solrTextQuery.phrase())).append("\"");
out.append("\"").append(XmlEscapers.xmlContentEscaper().escape(escapeQueryStringValue(solrTextQuery.phrase()))).append("\"");
if (solrTextQuery.slop() > 0 && hasMoreThanOneWord(solrTextQuery.phrase())) {
out.append("~").append(solrTextQuery.slop());
}