Fix the array and dict registering. The register() function has to be rethought, as resolve_type is doing more, and the ArrayType and DictType are in the game.
This commit is contained in:
parent
150dbd2de8
commit
d04f10c835
@ -474,10 +474,12 @@ class Registry(object):
|
||||
type_ = DictType(list(type_.keys())[0], list(type_.values())[0])
|
||||
if isinstance(type_, ArrayType):
|
||||
type_ = ArrayType(self.resolve_type(type_.item_type))
|
||||
self.array_types.append(type_)
|
||||
elif isinstance(type_, DictType):
|
||||
type_ = DictType(
|
||||
type_.key_type,
|
||||
self.resolve_type(type_.value_type))
|
||||
self.dict_types.append(type_)
|
||||
else:
|
||||
type_ = self.register(type_)
|
||||
return type_
|
||||
|
Loading…
x
Reference in New Issue
Block a user