Skip to content

Commit 9d8c57f

Browse files
author
Renan Chagas
committed
fix alredy exists mapping erro when both types has the same name (different modules/packages) on map() method
1 parent d5fcd50 commit 9d8c57f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mapper/object_mapper.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ def map(self, from_obj, to_type, ignore_case=False, allow_none=False, excluded=N
128128
from_obj.__dict__
129129

130130
inst = to_type()
131-
key_from = from_obj.__class__.__name__
132-
key_to = to_type.__name__
131+
key_from = from_obj.__class__
132+
key_to = to_type
133133

134134
def not_private(s):
135135
return not s.startswith('_')

0 commit comments

Comments
 (0)