Skip to content

Commit 56ca714

Browse files
committed
Catch explicitly exception ImportError for enchant
1 parent 1618ce7 commit 56ca714

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

msgcheck.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@
3535
# (argument -s/--spell)
3636
ENCHANT_FOUND = False
3737
try:
38-
import enchant
38+
from enchant import Dict, DictWithPWL, DictNotFoundError
3939
from enchant.checker import SpellChecker
4040
ENCHANT_FOUND = True
41-
except:
41+
except ImportError:
4242
pass
4343

4444
VERSION = '2.5-dev'

0 commit comments

Comments
 (0)