When the lock screen goes blank after a while (as it should) it immediately turns back on and waits the same while before going blank again and it starts over again. Making both the laptop screen and the external monitor turn on and off in a constant loop. I've turned off notifications on lock screen, so it's not that. But now I've got no clue how to fix it. It hasn't been like this always, but I can't figure out what made it so.
I've got Ubuntu 22.04 on a Lenovo-laptop with an external monitor (ASUS) on HDMI.