Skip to content

Commit d2c6aff

Browse files
author
Patrick Vos
committed
Merge branch 'fix_adding_existing_show_never_returns' into development
* fix_adding_existing_show_never_returns: Fix Exception on adding rootdir (unable to open NFO) Fix Exception on adding initial rootdir (ROOT_DIRS not set)
2 parents cfba3c6 + b60dedb commit d2c6aff

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

data/js/rootDirs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ $(document).ready(function() {
4343
setDefault($('#rootDirs option').attr('id'));
4444
}
4545

46-
refreshRootDirs();
4746
$.get(sbRoot + '/config/general/saveRootDirs', { rootDirString: $('#rootDirText').val() });
47+
refreshRootDirs();
4848

4949
}
5050

sickbeard/metadata/generic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -865,7 +865,7 @@ def retrieveShowMetadata(self, folder):
865865
logger.log(u"Invalid tvdb id (" + str(tvdb_id) + "), not using metadata file", logger.WARNING)
866866
return empty_return
867867

868-
except (exceptions.NoNFOException, SyntaxError, ValueError), e:
868+
except Exception, e:
869869
logger.log(u"There was an error parsing your existing metadata file: " + ex(e), logger.WARNING)
870870
return empty_return
871871

sickbeard/webserve.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1459,7 +1459,11 @@ def massAddTable(self, rootDir=None):
14591459

14601460
root_dirs = [urllib.unquote_plus(x) for x in root_dirs]
14611461

1462-
default_index = int(sickbeard.ROOT_DIRS.split('|')[0])
1462+
if sickbeard.ROOT_DIRS:
1463+
default_index = int(sickbeard.ROOT_DIRS.split('|')[0])
1464+
else:
1465+
default_index = 0
1466+
14631467
if len(root_dirs) > default_index:
14641468
tmp = root_dirs[default_index]
14651469
if tmp in root_dirs:

0 commit comments

Comments
 (0)