Skip to content

Commit 97847ca

Browse files
committed
Fix '-t in args' check
fixes #77
1 parent e19147e commit 97847ca

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tmuxp/pane.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def tmux(self, cmd, *args, **kwargs):
6767
:rtype: :class:`Server.tmux`
6868
6969
"""
70-
if not len([arg for arg in args if '-t' in arg]):
70+
if not any(arg.startswith('-t') for arg in args):
7171
args = ('-t', self.get('pane_id')) + args
7272

7373
return self.server.tmux(cmd, *args, **kwargs)

tmuxp/window.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def tmux(self, cmd, *args, **kwargs):
7676
:rtype: :class:`Server.tmux`
7777
7878
"""
79-
if not len([arg for arg in args if '-t' in str(arg)]):
79+
if not any(arg.startswith('-t') for arg in args):
8080
args = ('-t', self.get('window_id')) + args
8181

8282
return self.server.tmux(cmd, *args, **kwargs)

0 commit comments

Comments
 (0)