That Ibn 'Umar heard a man saying: "No by the Ka'bah" so Ibn 'Umar said: "Nothing is sworn by other than Allah, for I heard the Messenger of Allah ﷺ say: 'Whoever swears by other than Allah, he has committed disbelief or shirk.'"
سَمِعْتُ رَسُولَ اللَّهِ ﷺ يَقُولُ مَنْ حَلَفَ بِغَيْرِ اللَّهِ فَقَدْ كَفَرَ أَوْ أَشْرَكَ