Add some checks to remove displaying errors

This commit is contained in:
Melissa LeBlanc-Williams 2025-05-20 15:34:36 -07:00
parent 3448db64f0
commit 908629430e

View file

@ -654,6 +654,7 @@ WantedBy=multi-user.target
def uninstall_fbcp():
uninstall_fbcp_rclocal()
# Enable overscan compensation
if shell.exists("/etc/systemd/system/fbcp.service"):
shell.run_command("sudo systemctl disable fbcp.service")
# Set up HDMI parameters:
shell.run_command("raspi-config nonint do_overscan 0")
@ -665,7 +666,7 @@ def uninstall_fbcp():
shell.pattern_replace(f"{boot_dir}/config.txt", '^hdmi_mode=87.*$')
shell.pattern_replace(f"{boot_dir}/config.txt", '^hdmi_cvt=.*$')
if not wayland and not is_bullseye:
if not wayland and not is_bullseye and shell.exists("/etc/lightdm"):
print("Restoring Wayland as default display manager...")
shell.set_window_manager("wayland")