Sort the list alphabetticaly for bin search
This commit is contained in:
		@@ -29,7 +29,7 @@ class PokeSearchViewModel(private val favouritesRepository: FavouritesRepository
 | 
				
			|||||||
        viewModelScope.launch {
 | 
					        viewModelScope.launch {
 | 
				
			||||||
            try {
 | 
					            try {
 | 
				
			||||||
                val response = service.getPokemon()
 | 
					                val response = service.getPokemon()
 | 
				
			||||||
                _initialPokemonList.value = response.results
 | 
					                _initialPokemonList.value = response.results.sortedBy { it.name.lowercase() }
 | 
				
			||||||
            } catch (e: IOException) {
 | 
					            } catch (e: IOException) {
 | 
				
			||||||
                /*TODO*/
 | 
					                /*TODO*/
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user