mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
autodns dry-run: return a proper datastructure to the api instead of ~humanfriendly string
This commit is contained in:
parent
7655b7b7c3
commit
71b09ae0e7
1 changed files with 8 additions and 5 deletions
|
@ -726,6 +726,9 @@ def domain_registrar_push(operation_logger, domain, dry_run=False, force=False,
|
|||
return f'{name:>20} [{t:^5}] {old_content:^30} -> {new_content:^30} {ignored}'
|
||||
|
||||
if dry_run:
|
||||
if Moulinette.interface.type == "api":
|
||||
return changes
|
||||
else:
|
||||
out = {"delete": [], "create": [], "update": []}
|
||||
for action in ["delete", "create", "update"]:
|
||||
for record in changes[action]:
|
||||
|
|
Loading…
Add table
Reference in a new issue