From: Dennis Schafroth Date: Tue, 1 Nov 2011 12:30:21 +0000 (+0100) Subject: Suround by suggestions, if data in suggestions_xml X-Git-Tag: v1.6.5~1^2~5 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=ebc05bf9ed7336e6341bd94a07fa07063accc24b;p=pazpar2-moved-to-github.git Suround by suggestions, if data in suggestions_xml --- diff --git a/src/http_command.c b/src/http_command.c index 587c908..a86aabb 100644 --- a/src/http_command.c +++ b/src/http_command.c @@ -642,8 +642,11 @@ static void cmd_bytarget(struct http_channel *c) wrbuf_puts(c->wrbuf, ht[i].settings_xml); wrbuf_puts(c->wrbuf, "\n"); } - if (ht[i].suggestions_xml) + if (ht[i].suggestions_xml && ht[i].suggestions_xml[0]) { + wrbuf_puts(c->wrbuf, ""); wrbuf_puts(c->wrbuf, ht[i].suggestions_xml); + wrbuf_puts(c->wrbuf, ""); + } wrbuf_puts(c->wrbuf, ""); } response_close(c, "bytarget");