edited __getitem__