It works, I just want to make sure I did it correctly. It's a Leviton ODS10-ID Decora 120/277-Volt Wall Switch with Occupancy Sensor
When I took the original switch off the wall it had no ground connected and a red and black wire going to it.
I installed the green ground wire from the switch into the existing 3 bare copper wires that were in a yellow wire nut which I upgraded to a red since I was now adding a 4th wire. One bare wire connected to the metal box and the other two go into the wall.
I attached the black hot from the new switch into the black wire in the wall that was connected to the old switch. I attached the blue wire from the new switch to the red wire that was attached to the old switch.