I found a strange bug when running with phantomjs in headless mode while running on Codeship where node.classList was undefined rather than [], which caused everything to blow up with TypeError: 'undefined' is not an object (evaluating 'node.classList[0]'). This simple check fixes the problem.
Hey,
I found a strange bug when running with phantomjs in headless mode while running on Codeship where
node.classList
was undefined rather than[]
, which caused everything to blow up withTypeError: 'undefined' is not an object (evaluating 'node.classList[0]')
. This simple check fixes the problem.Let me know if you have any questions about it.