using in_typemapper instead of self.typemapper.keys for looking up resource_uri's now
This commit is contained in:
Родитель
e7bf79aa6a
Коммит
fd7636c4f8
|
@ -185,8 +185,8 @@ class Emitter(object):
|
||||||
ret[k] = _any(getattr(data, k))
|
ret[k] = _any(getattr(data, k))
|
||||||
|
|
||||||
# resouce uri
|
# resouce uri
|
||||||
if type(data) in self.typemapper.keys():
|
if self.in_typemapper(type(data), self.anonymous):
|
||||||
handler = self.typemapper.get(type(data))
|
handler = self.in_typemapper(type(data), self.anonymous)
|
||||||
if hasattr(handler, 'resource_uri'):
|
if hasattr(handler, 'resource_uri'):
|
||||||
url_id, fields = handler.resource_uri()
|
url_id, fields = handler.resource_uri()
|
||||||
ret['resource_uri'] = permalink( lambda: (url_id,
|
ret['resource_uri'] = permalink( lambda: (url_id,
|
||||||
|
|
Загрузка…
Ссылка в новой задаче