A cooked hotdog that has been left out overnight for just one night is safe to eat.
I've left cooked hotdogs out overnight and ate them the next day.
Sometimes I will have leftover hotdogs after cooking them and then be so busy with other things and then forget to refrigerate them for one night.
Then the next day I remember I left the hotdogs out.
The hotdogs are safe to eat still.
If you're worried about the hotdog containing bacteria you could boil the cooked hotdog for a few minutes as the boiling would kill any bacteria on the hotdog.
As long as the hotdog does not smell bad or has any mold on it then the hotdog is safe to eat.