Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
klen committed Dec 29, 2017
2 parents fc2a99a + 62b0e6f commit 65ab3bd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
@@ -1,6 +1,6 @@
[bumpversion]
commit = True
current_version = 6.0.0
current_version = 6.0.1
files = mixer/__init__.py
tag = True
tag_name = {new_version}
Expand Down
2 changes: 1 addition & 1 deletion mixer/__init__.py
Expand Up @@ -14,7 +14,7 @@
# Module information
# ==================

__version__ = "6.0.0"
__version__ = "6.0.1"
__project__ = "mixer"
__author__ = "horneds <horneds@gmail.com>"
__license__ = "BSD"
8 changes: 5 additions & 3 deletions mixer/factory.py
Expand Up @@ -2,6 +2,7 @@

import datetime
import decimal
import inspect

from . import _compat as _, mix_types as t
from ._faker import faker
Expand Down Expand Up @@ -141,9 +142,10 @@ def cls_to_simple(cls, fcls):
if fcls in cls.generators:
return fcls

for stype in cls.types:
if issubclass(fcls, stype):
return cls.types[stype]
if inspect.isclass(fcls):
for stype in cls.types:
if issubclass(fcls, stype):
return cls.types[stype]

return None

Expand Down

0 comments on commit 65ab3bd

Please sign in to comment.