Fixed a bug in has_mixed_content? reported by Dan Kubb.