Every user who has write access to the NAS can modify files which malware does.
To minimize the risk, create user accounts and restrict the access to folder for every user in NAS management. So if PC 1 get infected and had user credentials for NAS-user 1 only files from NAS-user 1 get infected.
With backups and ransomware protection on NAS side you're good then.
Also don't let your NAS open to unneeded stuff like SSH or at least only allow keyfile login.
And one important thing: disable all online services on NAS except automatic updates.
Cloud is a big attack surface for a NAS.