Skip to content

Commit

Permalink
pyanaconda: fix incorrect access to --repo argument
Browse files Browse the repository at this point in the history
The '--repo' argument has a variable destination of 'method'.
  • Loading branch information
KKoukiou committed Sep 20, 2024
1 parent 61d8ced commit 0d9431b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pyanaconda/payload/dnf/payload.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ def set_from_opts(self, opts):
def _set_default_source(self, opts):
"""Set the default source.
Set the source based on opts.repo if it isn't already set
- opts.repo is currently set by command line/boot options.
Set the source based on opts.method if it isn't already set
- opts.method is currently set by command line/boot options.
Otherwise, use the source provided at a specific mount point
by Dracut if there is any.
Expand All @@ -89,9 +89,9 @@ def _set_default_source(self, opts):
if self.proxy.Sources:
log.debug("The DNF source is already set.")

elif opts.repo:
elif opts.method:
log.debug("Use the DNF source from opts.")
source_proxy = self._create_source_from_url(opts.repo)
source_proxy = self._create_source_from_url(opts.method)
set_source(self.proxy, source_proxy)

elif verify_valid_repository(DRACUT_REPO_DIR):
Expand Down

0 comments on commit 0d9431b

Please sign in to comment.