fixed rendering bug