1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-09-28 16:12:36 +01:00

Now only return [] when correct error was caught

This commit is contained in:
Andrew Wonnacott
2016-11-03 03:46:27 -04:00
parent 5f6c55d839
commit b4fda04acb

View File

@@ -24,8 +24,11 @@ def get_pkgfile(command):
).splitlines()
return [package.split()[0] for package in packages]
except subprocess.CalledProcessError:
return []
except subprocess.CalledProcessError as err:
if err.returncode == 1 and err.output == "":
return []
else:
raise err
def archlinux_env():