fix outofarrayexception