Fixed assert bug