From e52692a16c8e31d1da3de5397df81b60eacec7d6 Mon Sep 17 00:00:00 2001 From: TomJGooding <101601846+TomJGooding@users.noreply.github.com> Date: Wed, 27 Nov 2024 10:26:26 +0000 Subject: [PATCH] refactor(select): utilize add_options method (#5256) --- src/textual/widgets/_select.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/textual/widgets/_select.py b/src/textual/widgets/_select.py index 3bb8e18e4e..c12d882eb9 100644 --- a/src/textual/widgets/_select.py +++ b/src/textual/widgets/_select.py @@ -425,8 +425,7 @@ def _setup_options_renderables(self) -> None: option_list = self.query_one(SelectOverlay) option_list.clear_options() - for option in self._select_options: - option_list.add_option(option) + option_list.add_options(self._select_options) def _init_selected_option(self, hint: SelectType | NoSelection = BLANK) -> None: """Initialises the selected option for the `Select`."""