mirror of
https://github.com/beetbox/beets.git
synced 2026-01-05 15:33:15 +01:00
Don't ask for confirmation if nothing changed
This commit is contained in:
parent
80facbab6f
commit
cfba04bc9d
1 changed files with 5 additions and 1 deletions
|
|
@ -221,8 +221,12 @@ class EditPlugin(plugins.BeetsPlugin):
|
|||
"""Save a list of updated Model objects to the database.
|
||||
"""
|
||||
# Display and confirm the changes.
|
||||
changed = False
|
||||
for obj in objs:
|
||||
ui.show_model_changes(obj)
|
||||
changed |= ui.show_model_changes(obj)
|
||||
if not changed:
|
||||
ui.print_('No changes to apply.')
|
||||
return
|
||||
if not ui.input_yn('Apply changes? (y/n)'):
|
||||
return
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue