diff --git a/examples/pokedex/src/main.rs b/examples/pokedex/src/main.rs index 882a195d..c737b87e 100644 --- a/examples/pokedex/src/main.rs +++ b/examples/pokedex/src/main.rs @@ -4,7 +4,7 @@ use iced::{Alignment, Command, Element, Length}; pub fn main() -> iced::Result { iced::application(Pokedex::title, Pokedex::update, Pokedex::view) - .load(Pokedex::load) + .load(Pokedex::search) .run() } @@ -25,7 +25,7 @@ enum Message { } impl Pokedex { - fn load() -> Command { + fn search() -> Command { Command::perform(Pokemon::search(), Message::PokemonFound) } @@ -56,7 +56,7 @@ impl Pokedex { _ => { *self = Pokedex::Loading; - Command::perform(Pokemon::search(), Message::PokemonFound) + Self::search() } }, }