How To: Disable laptop lid open / close events on any Linux using systemd

Edit /etc/systemd/logind.conf and change the HandleLidSwitch to the following:

Then you could try to restart the systemd-logind service with:

BUT it crashed my machine when I did, so perhaps just a reboot for it to take effect would be the best option.