fx-compat: DB.executeTransaction() no longer takes generator functions

This commit is contained in:
Dan Stillman 2020-07-05 06:20:01 -04:00
parent ccbc785499
commit 03242e8984
41 changed files with 319 additions and 320 deletions

View file

@ -15,12 +15,12 @@ describe("Zotero.Notifier", function () {
};
var id = Zotero.Notifier.registerObserver(observer, null, 'test_trigger');
yield Zotero.DB.executeTransaction(function* () {
yield Zotero.DB.executeTransaction(async function () {
var item = new Zotero.Item('book');
item.setField('title', 'A');
yield item.save();
await item.save();
item.setField('title', 'B');
yield item.save();
await item.save();
Zotero.Notifier.queue('unknown', 'item', item.id);
});