mirror of
https://github.com/zadam/trilium.git
synced 2025-10-29 17:26:38 +01:00
separate DB connection for each transaction (just for the record, will be reverted probably)
This commit is contained in:
@@ -29,8 +29,8 @@ router.post('/', async (req, res, next) => {
|
||||
if (ALLOWED_OPTIONS.includes(body['name'])) {
|
||||
const optionName = await options.getOption(body['name']);
|
||||
|
||||
await sql.doInTransaction(async () => {
|
||||
await options.setOption(body['name'], body['value']);
|
||||
await sql.doInTransaction(async db => {
|
||||
await options.setOption(db, body['name'], body['value']);
|
||||
});
|
||||
|
||||
res.send({});
|
||||
|
||||
Reference in New Issue
Block a user