1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-12-12 11:02:21 -05:00

Testing fix for 500 internal server error/TypeError: argument of type 'NoneType' is not iterable

This commit is contained in:
echel0n 2014-06-25 17:12:52 -07:00
parent 20aa4b6331
commit 67ae7af226

View File

@ -311,9 +311,7 @@ def main():
sickbeard.CFG = ConfigObj(sickbeard.CONFIG_FILE)
myDB = db.DBConnection()
CUR_DB_VERSION = myDB.checkDBVersion()
CUR_DB_VERSION = db.DBConnection().checkDBVersion()
if CUR_DB_VERSION > 0:
if CUR_DB_VERSION < MIN_DB_VERSION:
@ -327,16 +325,20 @@ def main():
MAX_DB_VERSION) + ").\n" + \
"If you have used other forks of SB, your database may be unusable due to their modifications.")
# Initialize the config and our threads
sickbeard.initialize(consoleLogging=consoleLogging)
sickbeard.showList = []
if sickbeard.DAEMON:
daemonize()
# Use this PID for everything
sickbeard.PID = os.getpid()
# Initialize the config and our threads
sickbeard.initialize(consoleLogging=consoleLogging)
sickbeard.showList = []
# Build from the DB to start with
logger.log(u"Loading initial show list")
loadShowsFromDB()
if forcedPort:
logger.log(u"Forcing web server to port " + str(forcedPort))
@ -376,10 +378,6 @@ def main():
# init tornado
webserveInit.initWebServer(options)
# Build from the DB to start with
logger.log(u"Loading initial show list")
loadShowsFromDB()
def startup():
# Fire up all our threads
sickbeard.start()