Python3: use dict instead of types.DictType

Signed-off-by: IWAMOTO Toshihiro <iwamoto@valinux.co.jp>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
IWAMOTO Toshihiro 2015-10-16 14:42:34 +09:00 committed by FUJITA Tomonori
parent 604b16c565
commit d5bb8d4603

@ -9,7 +9,6 @@ public. They will stay private and only "view" will access them
(think friend-class from C++)
"""
import logging
import types
from ryu.services.protocols.bgp.operator.views import fields
@ -256,7 +255,7 @@ def _flatten(l, max_level=10):
:return: flattened iterator
"""
if max_level >= 0:
_iter = l.values() if isinstance(l, types.DictType) else l
_iter = l.values() if isinstance(l, dict) else l
for el in _iter:
if isinstance(el, RdyToFlattenCollection):
for sub in _flatten(el, max_level=max_level - 1):