Skip to content

Commit

Permalink
Avoid reassigning a parameter value to fix Pyright warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
correctmost committed Jan 11, 2025
1 parent e7f2a8c commit 9b9ee91
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions archinstall/lib/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,11 @@ def save_user_creds(self, dest_path: Path) -> None:
target.chmod(stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP)

def save(self, dest_path: Path | None = None) -> None:
dest_path = dest_path or self._default_save_path
save_path = dest_path or self._default_save_path

if self._is_valid_path(dest_path):
self.save_user_config(dest_path)
self.save_user_creds(dest_path)
if self._is_valid_path(save_path):
self.save_user_config(save_path)
self.save_user_creds(save_path)


def save_config(config: dict[str, Any]) -> None:
Expand Down

0 comments on commit 9b9ee91

Please sign in to comment.