File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -420,6 +420,10 @@ func (o *redhatBase) scanPackages() (err error) {
420
420
return xerrors .Errorf ("Failed to scan installed packages: %w" , err )
421
421
}
422
422
423
+ if err := o .yumMakeCache (); err != nil {
424
+ return xerrors .Errorf ("Failed to execute `yum makecache`: %w" , err )
425
+ }
426
+
423
427
if o .EnabledDnfModules , err = o .detectEnabledDnfModules (); err != nil {
424
428
return xerrors .Errorf ("Failed to detect installed dnf modules: %w" , err )
425
429
}
@@ -645,10 +649,6 @@ func (o *redhatBase) yumMakeCache() error {
645
649
}
646
650
647
651
func (o * redhatBase ) scanUpdatablePackages () (models.Packages , error ) {
648
- if err := o .yumMakeCache (); err != nil {
649
- return nil , xerrors .Errorf ("Failed to `yum makecache`: %w" , err )
650
- }
651
-
652
652
isDnf := o .exec (util .PrependProxyEnv (`repoquery --version | grep dnf` ), o .sudo .repoquery ()).isSuccess ()
653
653
cmd := `repoquery --all --pkgnarrow=updates --qf='%{NAME} %{EPOCH} %{VERSION} %{RELEASE} %{REPO}'`
654
654
if isDnf {
You can’t perform that action at this time.
0 commit comments