From ebf2dd5c80f35ad387d52eda3c3d340d02bbc69d Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Fri, 11 Aug 2023 10:57:45 -0700 Subject: [PATCH] backups: Remove use of length_is template function - It has been deprecated in Django 4.2 Tests: - Add a remote backup location with valid SSH hostname and notice that the list of SSH host keys are shown properly. - Add a remote backup location with invalid SSH hostname and notice that the error "Could not reach SSH host..." is shown. Signed-off-by: Sunil Mohan Adapa Reviewed-by: James Valleroy --- plinth/modules/backups/templates/verify_ssh_hostkey.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plinth/modules/backups/templates/verify_ssh_hostkey.html b/plinth/modules/backups/templates/verify_ssh_hostkey.html index 731659972..78d059c65 100644 --- a/plinth/modules/backups/templates/verify_ssh_hostkey.html +++ b/plinth/modules/backups/templates/verify_ssh_hostkey.html @@ -13,7 +13,7 @@
{% csrf_token %} - {% if form.ssh_public_key|length_is:"0" %} + {% if form.ssh_public_key|length == 0 %}

{% blocktrans trimmed %} Could not reach SSH host {{ hostname }}. Please verify that the host