ghickman/tvrenamr — Issue #9: Crash when "defaults" not specified in config
Author: sampsyo
Created: 2011-11-16 19:56:35+00:00
State: open

If the user doesn't have a "defaults" dict in `config.yaml`, the `defaults` field on the `Config` object is None because this method returns None implicitly: https://github.com/ghickman/tvrenamr/blob/master/tvrenamr/config.py#L96

Then, later, when a config value is looked up, `defaults` is assumed to exist: https://github.com/ghickman/tvrenamr/blob/master/tvrenamr/config.py#L27

This raises a "TypeError: 'NoneType' object is not subscriptable" error, which is not handled. You probably want this somewhere in there:

if not self.defaults:
return False