I faced an issue where LightDM was not working only when switching to Nvidia (I think it worked first time but I don't remember exactly), hybrid and integrated worked fine, Nvidia mode also worked in SDDM but didn't in LightDM. After some digging I found that 20-nvidia.conf was not getting regenerated, causing xrandr script to not run.
This change ensures that 20-nvidia.conf always gets generated in LightDM for Nvidia mode.
Checking for lightdm.conf.d directory is not needed as it generates parent directories if it doesn't exist
I faced an issue where LightDM was not working only when switching to Nvidia (I think it worked first time but I don't remember exactly), hybrid and integrated worked fine, Nvidia mode also worked in SDDM but didn't in LightDM. After some digging I found that 20-nvidia.conf was not getting regenerated, causing xrandr script to not run.
This change ensures that 20-nvidia.conf always gets generated in LightDM for Nvidia mode.
Checking for lightdm.conf.d directory is not needed as it generates parent directories if it doesn't exist