2nd which unneccesary

This commit is contained in:
Kovid Goyal 2022-03-06 22:25:03 +05:30
parent 99e1605bba
commit 33de55540b
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -1329,7 +1329,7 @@ def prepare_arg(x: str) -> str:
tab = self.active_tab
if tab is not None:
bdata = data.encode('utf-8') if isinstance(data, str) else data
if is_macos and which(cmd[0]) == '/usr/bin/less':
if is_macos and cmd[0] == '/usr/bin/less':
# the system less on macOS barfs up OSC codes, so sanitize them ourselves
bdata = re.sub(br'\x1b\].*?\x1b\\', b'', bdata)