add isinstance check for context

This commit is contained in:
yumoqing 2019-10-21 14:50:37 +08:00
parent 050cf70e24
commit 9aba83f1b8

View File

@ -62,7 +62,7 @@ class BaseProcessor:
await self.datahandle(request)
if self.retResponse is not None:
return self.retResponse
if type(self.content) == type({}):
if type(self.content) == type({}) or isinstance(self,DictObject):
self.content = json.dumps(self.content,
indent=4)
if type(self.content) == type([]):