Suspend via keyboard shortcut fails

I am trying to map a keyboard shortcut to put my computer to sleep.


I have successfully enabled my user to run the command without prompt.

and when I run

sudo systemctl suspend

via terminal it works perfectly.

However, when I run my new keyboard shortcut, it works perfectly and goes to sleep for 1 second before immediately resuming.

Any advice?

Well that was simple. Fix was there was already a built in keyboard shortcut for sleep so I didn’t even have to use the terminal command.