Fix HasNext() and Next()