Skip to content
Prev Previous commit
Next Next commit
Fix class check.
  • Loading branch information
tonysyu committed Jan 17, 2014
commit e0eee67a370b5e4d1e962a50779a47395374327c
3 changes: 2 additions & 1 deletion lib/matplotlib/config/mpl_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import six
from collections import namedtuple, defaultdict
from copy import copy
import inspect
import json

from functools import wraps
Expand Down Expand Up @@ -172,7 +173,7 @@ def string_to_class(klass):
raise_invalid_class_path_error(split_klass)
last_level = getattr(last_level, _k)

if not isinstance(last_level, object):
if not inspect.isclass(last_level):
raise_invalid_class_path_error(split_klass)

return last_level
Expand Down