bundles/basic: use metadata.get()

This commit is contained in:
Franzi 2023-11-29 16:41:03 +01:00
parent d364b3c152
commit a21102724a
Signed by: kunsi
GPG key ID: 12E3D2136B818350

View file

@ -30,7 +30,7 @@ files = {
}
locale_needs = set()
for locale in sorted(node.metadata['locale']['installed']):
for locale in sorted(node.metadata.get('locale/installed')):
actions[f'ensure_locale_{locale}_is_enabled'] = {
'command': f"sed -i '/{locale}/s/^# *//g' /etc/locale.gen",
'unless': f"grep -e '^{locale}' /etc/locale.gen",