From cfb5f7590154b9e648594362d7101719b2c96f25 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Tue, 11 Oct 2016 11:12:36 +0300 Subject: [PATCH] Fix repository error message --- slpkg/main.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/slpkg/main.py b/slpkg/main.py index deb64231..84c6ef89 100644 --- a/slpkg/main.py +++ b/slpkg/main.py @@ -265,12 +265,14 @@ class ArgParse(object): usage("") raise SystemExit() if (len(self.args) > 1 and len(self.args) <= 5 and - self.args[0] in options and - self.args[1] in self.meta.repositories): - PackageManager(binary=None).package_list(self.args[1], - name, - INDEX, - installed) + self.args[0] in options): + if self.args[1] in self.meta.repositories: + PackageManager(binary=None).package_list(self.args[1], + name, + INDEX, + installed) + else: + usage(self.args[1]) else: usage("")