fix rendering bug