Katherine said "Humanity is a vampire's greatest weakness" and indeed that's what happened. At the beginning of the episode Stefan told Damon and Elena, it's usually one of them who let in their humanity get in the way and at the end – it was him who screws up their plan cause of his humanity. But it was not just him alone, even Katherine's humanity showed here. She loved them both and fought to save her both ex loves( deep down, I think it was so save Stefan as his brother is his humanity, loosing Damon means losing Stefan forever). It was her who told him to start to care and went ahead with Damon's plan with a hope of Stefan turning up there on time.
Both sacrificed their freedom for save Damon and Damon was ready to die as well by killing Klaus though he was not aware of the reason behind Stefan's betrayal. His plan was so very smart and he didn't know he got back his brother and his humanity. You are your brother's humanity and have just turned on it without even realizing it.
PS! Klaus –Stefan was also nice. For once, I think Klaus really meant it when he said "thank you my friend". You could sense the sincerity cause just few moments before, his so called father has told him, he is and will always be a loner and here Stefan rescued him.
And I really don't think Elena and Damon have given up on Stefan, it was an instant reaction because they taught Stefan betrayed them. Anyone would have felt the same way like them, they took a big risk to kill Klaus and the person they did all of this for, comes and screws up their entire plan. Of course anyone will be angry so it was an natural reaction.
I am exited to see how this revenge plan works out!!!
Epic mid season finale😎