compatibility for JSDOM 1.5