mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-11-29 08:25:10 +00:00
diagnostics: Translate descriptions only in view
Tests: - Enable all apps, and run diagnostics. Diagnostic descriptions are formatted as expected. - Change the language to Spanish, and view the diagnostic results. Diagnostic descriptions are translated as expected. Signed-off-by: James Valleroy <jvalleroy@mailbox.org> Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
1 parent
a5820bc36d
commit
3fcd6b9e58
18 files changed
+101
-89
No files matched your search
@@ -6,6 +6,7 @@ import logging
|
||||
import pathlib
|
||||
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from django.utils.translation import gettext_noop
|
||||
|
||||
from plinth import app as app_module
|
||||
from plinth import cfg, menu
|
||||
@@ -13,6 +14,7 @@ from plinth.config import DropinConfigs
|
||||
from plinth.modules import names
|
||||
from plinth.modules.apache.components import diagnose_url
|
||||
from plinth.modules.backups.components import BackupRestore
|
||||
from plinth.modules.diagnostics.check import DiagnosticCheck, Result
|
||||
from plinth.modules.names.components import DomainType
|
||||
from plinth.package import Packages
|
||||
from plinth.signals import domain_added, domain_removed, post_app_loading
|
||||
@@ -97,7 +99,10 @@ class LetsEncryptApp(app_module.App):
|
||||
|
||||
if not results:
|
||||
results.append(
|
||||
(_('Cannot test: No domains are configured.'), 'warning'))
|
||||
DiagnosticCheck(
|
||||
'letsencrypt-cannot-test',
|
||||
gettext_noop('Cannot test: No domains are configured.'),
|
||||
Result.WARNING))
|
||||
|
||||
return results
|
||||
|
||||
|
||||
Reference in new issue
Block a user