I don't believe it ever beat him, the Joker somehow used the 5 D imp magic to attach Spectre onto the Universe, if Spectre broke away (which he could have) he would have destroyed the Universe which he didn't want to do so he couldn't do anything at that time, i think thats how it happened. Don't know how the Joker got the Spectre there though.