Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Hvornum <anton.feeds+github@gmail.com>2020-11-11 22:18:22 +0000
committerAnton Hvornum <anton.feeds+github@gmail.com>2020-11-11 22:18:22 +0000
commitb00f307a287ef7ef32d5c9988d79cf60d09c26ae (patch)
treecefc863ed26462af8c76741a26fc1df89a453ab4
parentf6460b8634d2ac3bbdec5e7dc542b07ac1badea5 (diff)
Added minor error handling in installer.set_keyboard_language()
-rw-r--r--archinstall/lib/installer.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py
index c233a876..543f2ca3 100644
--- a/archinstall/lib/installer.py
+++ b/archinstall/lib/installer.py
@@ -292,7 +292,8 @@ class Installer():
pass
def set_keyboard_language(self, language):
- with open(f'{self.mountpoint}/etc/vconsole.conf', 'w') as vconsole:
- vconsole.write(f'KEYMAP={language}\n')
- vconsole.write(f'FONT=lat9w-16\n')
+ if len(language.strip()):
+ with open(f'{self.mountpoint}/etc/vconsole.conf', 'w') as vconsole:
+ vconsole.write(f'KEYMAP={language}\n')
+ vconsole.write(f'FONT=lat9w-16\n')
return True \ No newline at end of file