UNPKG

typeorm-transactional-async-callbacks

Version:

A Transactional Method Decorator for typeorm that uses cls-hooked to handle and propagate transactions between different repositories and service methods. Inpired by Spring Trasnactional Annotation and Sequelize CLS

12 lines 395 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isDataSource = void 0; var typeorm_1 = require("typeorm"); var isDataSource = function (value) { if (!value || typeof value !== 'object') { return false; } return value.constructor.name === typeorm_1.DataSource.name; }; exports.isDataSource = isDataSource; //# sourceMappingURL=index.js.map