1
1
mirror of https://github.com/KenanZhu/AutoLibrary.git synced 2026-06-17 23:13:03 +08:00

style(LibLogout): unify the format style of LibLogout.py

This commit is contained in:
2025-11-08 00:14:27 +08:00
parent d5dc012ade
commit b10d333eb2
-6
View File
@@ -44,19 +44,13 @@ class LibLogout(LibOperator):
if self.__driver is None:
self._showTrace("未提供有效 WebDriver 实例 !")
return False
try:
self.__driver.find_element(
By.XPATH, "//a[@href='/logout']"
).click()
self._showTrace(f"用户 {username} 注销成功 !")
return True
except Exception as e:
self._showTrace(f"用户 {username} 注销失败 ! : {e}")
return False