diff --git a/plinth/modules/dynamicdns/__init__.py b/plinth/modules/dynamicdns/__init__.py index 033ac3d4f..4e3630b4c 100644 --- a/plinth/modules/dynamicdns/__init__.py +++ b/plinth/modules/dynamicdns/__init__.py @@ -240,6 +240,20 @@ def get_status(): status = kvstore.get_default('dynamicdns_status', '{}') status = json.loads(status) status.setdefault('domains', {}) + + domains = get_config()['domains'] + for domain in domains: + if domain not in status['domains']: + # No status available for newly configured domain + status['domains'][domain] = { + 'domain': domain, + 'result': False, + 'ip_address': None, + 'error_code': None, + 'error_message': None, + 'timestamp': 0, + } + return status diff --git a/plinth/modules/dynamicdns/templates/dynamicdns.html b/plinth/modules/dynamicdns/templates/dynamicdns.html index 55a498fba..79f494ece 100644 --- a/plinth/modules/dynamicdns/templates/dynamicdns.html +++ b/plinth/modules/dynamicdns/templates/dynamicdns.html @@ -40,12 +40,20 @@ {{ domain.domain }} -