From 7fafdfcd9f5fed32a6be0eb3ff21406a2fae5357 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 22 Jul 2015 14:35:55 +0530 Subject: [PATCH] Proper error message when hunspell fails to load --- src/calibre/spell/dictionary.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/spell/dictionary.py b/src/calibre/spell/dictionary.py index 05ffdb7d92..630320ffdf 100644 --- a/src/calibre/spell/dictionary.py +++ b/src/calibre/spell/dictionary.py @@ -21,7 +21,7 @@ Dictionary = namedtuple('Dictionary', 'primary_locale locales dicpath affpath bu LoadedDictionary = namedtuple('Dictionary', 'primary_locale locales obj builtin name id') hunspell = plugins['hunspell'][0] if hunspell is None: - raise RuntimeError('Failed to load hunspell: %s' % plugins[1]) + raise RuntimeError('Failed to load hunspell: %s' % plugins['hunspell'][1]) dprefs = JSONConfig('dictionaries/prefs.json') dprefs.defaults['preferred_dictionaries'] = {} dprefs.defaults['preferred_locales'] = {}