Don't show '0 results' on error page, refs #619

This commit is contained in:
Simon Willison 2021-06-01 21:09:10 -07:00
commit f40d1b99d6
2 changed files with 2 additions and 1 deletions

View file

@ -80,7 +80,7 @@
</tbody> </tbody>
</table></div> </table></div>
{% else %} {% else %}
{% if not canned_write %} {% if not canned_write and not error %}
<p class="zero-results">0 results</p> <p class="zero-results">0 results</p>
{% endif %} {% endif %}
{% endif %} {% endif %}

View file

@ -1410,6 +1410,7 @@ def test_query_error(app_client):
'<textarea id="sql-editor" name="sql">select * from notatable</textarea>' '<textarea id="sql-editor" name="sql">select * from notatable</textarea>'
in html in html
) )
assert "0 results" not in html
def test_config_template_debug_on(): def test_config_template_debug_on():