@steven-canary, if your commands don't accept parameters, then whether your virtual switch is on or off, it just runs the command when you toggle the virtual switch on or off.
Or, in the SmartThings device handler code, you can remove the // in front of off(). That would make all of your virtual switches push buttons that automatically toggle themselves back off as soon you toggle them on.
// handle commands
def on() {
log.debug "Executing 'on'"
sendEvent(name:"switch",value:on)
parent.on(this)
}