From db87a9e7dd1b363fa1eed226ebac99b57360f4f0 Mon Sep 17 00:00:00 2001 From: Jon Tibble Date: Tue, 27 Jul 2010 16:07:00 +0100 Subject: [PATCH] Exception handling fixes in bible import --- openlp/plugins/bibles/forms/importwizardform.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/openlp/plugins/bibles/forms/importwizardform.py b/openlp/plugins/bibles/forms/importwizardform.py index ba48ed5fb..371dcfa56 100644 --- a/openlp/plugins/bibles/forms/importwizardform.py +++ b/openlp/plugins/bibles/forms/importwizardform.py @@ -327,6 +327,7 @@ class ImportWizardForm(QtGui.QWizard, Ui_BibleImportWizard): #Load and store Crosswalk Bibles filepath = AppLocation.get_directory(AppLocation.PluginsDir) filepath = os.path.join(filepath, u'bibles', u'resources') + books_file = None try: self.web_bible_list[WebDownload.Crosswalk] = {} books_file = open( @@ -348,6 +349,7 @@ class ImportWizardForm(QtGui.QWizard, Ui_BibleImportWizard): if books_file: books_file.close() #Load and store BibleGateway Bibles + books_file = None try: self.web_bible_list[WebDownload.BibleGateway] = {} books_file = open(os.path.join(filepath, u'biblegateway.csv'), 'r')