refactor(createThermograph): endpoint rollsback only if transaction was created in it
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
c4e51146fd
commit
8bdb02c0fc
|
@ -96,7 +96,7 @@ module.exports = Self => {
|
|||
|
||||
return travelThermograph;
|
||||
} catch (err) {
|
||||
await tx.rollback();
|
||||
if (tx) await tx.rollback();
|
||||
throw err;
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue