diff --git a/storage/compat/common.py b/storage/compat/common.py index 9de5ce6..84d8bd5 100644 --- a/storage/compat/common.py +++ b/storage/compat/common.py @@ -3,7 +3,6 @@ """Compatibility layer on scopes.storage: common functionality.""" from sqlalchemy import Table, Column, Index, BigInteger, Text -from zope.sqlalchemy import mark_changed from scopes.storage import common @@ -24,7 +23,7 @@ class Storage(common.Storage): if n == 0: stmt = t.insert().values(legacy=ouid, prefix=prefix, id=id) self.session.execute(stmt) - mark_changed(self.session) + self.mark_changed() def getUidTable(self, schema=None): #table = getExistingTable(self.storage, self.tableName) diff --git a/util.py b/util.py index aecdb95..b3d5040 100644 --- a/util.py +++ b/util.py @@ -138,7 +138,7 @@ def makeStorage(context): root = context.getLoopsRoot() opts = IOptions(root) schema = (opts.scopes.storage.schema or [None])[0] - return Storage(schema=schema) + return storageFactory(schema=schema) def records(context, name, factory, storage=None): root = context.getLoopsRoot()