Trying to setup Shutdown Button script

Trying to setup software/hardware shutdown reboot buttons. I’m using an old XBox. I’ve got the correct buttons hooked up to the right GPIO. If I push the power button it shuts down as expected but if I hit the eject(REBOOT) button, it shuts down the RPi2 as well. I’m using these scripts:

pishutdown.service (I use this systemd start file instead of rc.local as suggests, got it from another shutdown script that didn’t include a reboot option, both were found on github):