Fix HTML duplicate attribute bug