Skip to content

Commit b99c470

Browse files
[py] used truthy check instead of checking for length in to_capabilities method in ie/options.py (#12262)
[py] used truthy check insted of len in to_capabilities method in ie/options.py Co-authored-by: Diego Molina <diemol@users.noreply.github.com>
1 parent 92256a0 commit b99c470

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

py/selenium/webdriver/ie/options.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,13 +322,13 @@ def to_capabilities(self) -> dict:
322322
caps = self._caps
323323

324324
opts = self._options.copy()
325-
if len(self._arguments) > 0:
325+
if self._arguments:
326326
opts[self.SWITCHES] = " ".join(self._arguments)
327327

328-
if len(self._additional) > 0:
328+
if self._additional:
329329
opts.update(self._additional)
330330

331-
if len(opts) > 0:
331+
if opts:
332332
caps[Options.KEY] = opts
333333
return caps
334334

0 commit comments

Comments
 (0)