Skip to content

Commit

Permalink
Merge pull request #1207 from brunal/master
Browse files Browse the repository at this point in the history
Don't crash when no argument is given
  • Loading branch information
sampsyo committed Jan 6, 2015
2 parents b027e48 + 054488e commit 5add272
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion beets/ui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,8 @@ def _raw_main(args, lib=None):
# Special case for the `config --edit` command: bypass _setup so
# that an invalid configuration does not prevent the editor from
# starting.
if subargs[0] == 'config' and ('-e' in subargs or '--edit' in subargs):
if subargs and subargs[0] == 'config' \
and ('-e' in subargs or '--edit' in subargs):
from beets.ui.commands import config_edit
return config_edit()

Expand Down

0 comments on commit 5add272

Please sign in to comment.