Skip to content

Commit

Permalink
Add lib parameter for cli_exit
Browse files Browse the repository at this point in the history
  • Loading branch information
dangmai committed Jan 31, 2013
1 parent 63d939d commit 2ad5b4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion beets/ui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -716,14 +716,14 @@ def _raw_main(args, load_config=True):

# Invoke the subcommand.
subcommand.func(lib, suboptions, subargs)
plugins.send('cli_exit', lib=lib)

def main(args=None):
"""Run the main command-line interface for beets. Includes top-level
exception handlers that print friendly error messages.
"""
try:
_raw_main(args)
plugins.send('cli_exit')
except UserError as exc:
message = exc.args[0] if exc.args else None
log.error(u'error: {0}'.format(message))
Expand Down

0 comments on commit 2ad5b4c

Please sign in to comment.