Workaround for text node problem (needs to be fixed upstream)