diff --git a/slpkg/checks.py b/slpkg/checks.py index 2e6f73f7..aced58a2 100644 --- a/slpkg/checks.py +++ b/slpkg/checks.py @@ -14,7 +14,6 @@ class Check(Configs): def __init__(self): super(Configs, self).__init__() - self.black = Blacklist() self.utils = Utilities() self.color = self.colour() diff --git a/slpkg/views/view_package.py b/slpkg/views/view_package.py index 1cbf4c99..558128e5 100644 --- a/slpkg/views/view_package.py +++ b/slpkg/views/view_package.py @@ -10,14 +10,14 @@ from slpkg.models.models import session as Session from slpkg.models.models import SBoTable, PonceTable -class ViewPackage(Configs, Utilities): +class ViewPackage(Configs): """ View the repository packages. """ def __init__(self, flags: list): super(Configs, self).__init__() - super(Utilities, self).__init__() self.flags: list = flags + self.utils = Utilities() self.session = Session self.flag_pkg_version: list = ['-p', '--pkg-version'] @@ -58,12 +58,12 @@ class ViewPackage(Configs, Utilities): ).filter(self.sbo_table.name == package).first() path = Path(self.repo_path, info[9], info[0], 'README') - readme = self.read_file(path) + readme = self.utils.read_file(path) path = Path(self.repo_path, info[9], info[0], f'{info[0]}.info') - info_file = self.read_file(path) + info_file = self.utils.read_file(path) - repo_build_tag = self.read_build_tag(info[0]) + repo_build_tag = self.utils.read_build_tag(info[0]) maintainer, email, homepage = '', '', '' for line in info_file: # type: ignore @@ -76,7 +76,7 @@ class ViewPackage(Configs, Utilities): deps: str = (', '.join([f'{cyan}{pkg}' for pkg in info[2].split()])) - if self.is_option(self.flag_pkg_version, self.flags): + if self.utils.is_option(self.flag_pkg_version, self.flags): deps: str = (', '.join([f'{cyan}{pkg}{endc}-{yellow}{SBoQueries(pkg).version()}' f'{green}' for pkg in info[2].split()]))