resolves #819 match URL macro after entity; credit to @jmbruel