fix: set category before title to prevent form field reset (#763)

This commit is contained in:
Alex Strutsysnkyi
2026-01-10 15:28:00 +01:00
committed by GitHub
parent 7d8a0c43d9
commit f8a9c8e942

View File

@@ -944,16 +944,16 @@ class KleinanzeigenBot(WebScrapingMixin):
if ad_cfg.type == "WANTED": if ad_cfg.type == "WANTED":
await self.web_click(By.ID, "adType2") await self.web_click(By.ID, "adType2")
#############################
# set category (before title to avoid form reset clearing title)
#############################
await self.__set_category(ad_cfg.category, ad_file)
############################# #############################
# set title # set title
############################# #############################
await self.web_input(By.ID, "postad-title", ad_cfg.title) await self.web_input(By.ID, "postad-title", ad_cfg.title)
#############################
# set category
#############################
await self.__set_category(ad_cfg.category, ad_file)
############################# #############################
# set special attributes # set special attributes
############################# #############################