Skip to content

Commit

Permalink
fix: Avoid query in case of no packages
Browse files Browse the repository at this point in the history
  • Loading branch information
achillesrasquinha committed Dec 22, 2018
1 parent 0a3d600 commit eecaf31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pipupgrade/commands/__init__.py
Expand Up @@ -154,7 +154,7 @@ def command(requirements = [ ], latest = False, user = False, check = False, yes
spackages = pluralize("package", npackages) # Packages "string"

query = "Do you wish to update %s %s?" % (npackages, spackages)
if yes or cli.confirm(query):
if npackages and (yes or cli.confirm(query)):
for i, package in enumerate(dinfo):
if package.diff_type != "major" or latest:
cli.echo(cli_format(
Expand Down

0 comments on commit eecaf31

Please sign in to comment.