Sayyiduna Ibn Abbas (may Allah be pleased with them both) said: When (all the) people were made to leave the mosque and Ali (may Allah be pleased with him) was left, the people talked about it. This reached the Prophet (peace and blessings be upon him), and he (peace and blessings be upon him) said: "I did not make you leave on my own account, nor did I leave him on my own account; rather, Allah made you leave and left him. I am only a servant under command; whatever I am commanded, that I do." "I only follow what is revealed to me" [Al-An'am: 50].
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 12668