diff --git a/management/backup.py b/management/backup.py index 93136bf5..8de37ba5 100755 --- a/management/backup.py +++ b/management/backup.py @@ -473,6 +473,8 @@ def backup_set_custom(env, target, target_user, target_pass, min_age): config["target_pass"] = target_pass config["min_age_in_days"] = min_age + write_backup_config(env, config) + # Validate. try: if config["target"] not in ("off", "local"): @@ -482,8 +484,6 @@ def backup_set_custom(env, target, target_user, target_pass, min_age): except ValueError as e: return str(e) - write_backup_config(env, config) - return "OK" def get_backup_config(env, for_save=False, for_ui=False):