Being a hardware sort of bloke I would simply put a capacitor across the push button. It's not too critical but a 0.1uF usually does the trick. That way you solve the problem at source.
Hi Mike, I guess if you are a hardware guy then soldering a capacitor would seem is easier than adding two lines of code ![]()