Hi,
If the user don't have any privilege credential, it can't run the code again other servers .
For example , one user without privilege rights logs onto PC1, the code can be run against PC1, means he can get the members of the local administrator group for PC1 only, but can't get the members of the local administrator group for other PCs, the command will fail .
But when you run this command as domain admins you can run the command against any PCs.
Following screenshot for your reference (the user logs onto the client1, will failed to get the membership for server1, but will be successful for client1 itself and both will be ok if run as domain administrator):