Can a digital meter be damaged when reading resistance but connected to AC voltage
Short answer, it's perfectly safe for you (*) and the meter. At least when using a quality meter such as Fluke. Fluke is protected up to 1000Vrms on non-current inputs. Obviously 1kV is not safe for YOU but the meter won't mind. Here's the datasheet of the 170 series DMMS.

Here's a youtube video that explains more about DMM protection than you possibly would want to know.

And here's a link to the Fluke 27 service manual he uses as basis.

(*) Perfectly safe is probably going too far. According to IEC62368-1, 50VAC rms is safe for "instructed person" i.e. service guys. 30VAC rms is safe-safe. Still, 50VAC is unlikely to harm you in most cases. IEC TS 60479-1 classifies that as AC-2 and describes it thus: "Perception and involuntary muscular contractions likely but usually no
harmful electrical physiological effects"