fixed double render bug