fixed wrong indexing