mirror of
https://github.com/krateng/maloja.git
synced 2026-02-12 22:34:12 -05:00
8 lines
197 B
Python
8 lines
197 B
Python
from simplejson import JSONEncoder
|
|
|
|
def newdefault(self,object):
|
|
return getattr(object.__class__,"__json__", olddefault)(object)
|
|
|
|
olddefault = JSONEncoder.default
|
|
JSONEncoder.default = newdefault
|