Steve Piercy
2017-07-27 c3ca82935c6ecfbd1464e8adbf36554dff1f3b3e
1
2
3
4
5
6
7
8
9
10
11
12
from persistent.mapping import PersistentMapping
 
 
class MyModel(PersistentMapping):
    __parent__ = __name__ = None
 
 
def appmaker(zodb_root):
    if 'app_root' not in zodb_root:
        app_root = MyModel()
        zodb_root['app_root'] = app_root
    return zodb_root['app_root']