And if that had gone slightly wrong, this person would have gotten fired and also a bad reputation in an industry that is smaller than people think.
(Have seen an engineering team liquidated the day after successful delivery, death marched to it, for example)
If the chipper younger dev had failed, we wouldn't be reading this story. so there's survivors bias at play here. but we were all young and dumb like that at some point in our lives. it worked out for some but not for others. some exit the field entirely and go find other vocations.
So there's really absolutely no risk to do this.
Either way you will be fired/laid off, so why not just do it.
Cant fire the CTO, after all. It wasn’t his fault his stupid plan didn’t work. It can’t be the big successful company his friend runs. It’s the disposable staff who screwed up.