fixed hasnext