mirror of
https://github.com/bknd-io/bknd/
synced 2026-08-03 08:36:01 +00:00
Merge pull request #273 from bknd-io/feat/schema-batch-statements
feat: batch schema manager statements
This commit is contained in:
@@ -34,7 +34,6 @@ export class EntityManager<TBD extends object = DefaultDB> {
|
||||
private _entities: Entity[] = [];
|
||||
private _relations: EntityRelation[] = [];
|
||||
private _indices: EntityIndex[] = [];
|
||||
private _schema?: SchemaManager;
|
||||
readonly emgr: EventManager<typeof EntityManager.Events>;
|
||||
static readonly Events = { ...MutatorEvents, ...RepositoryEvents };
|
||||
|
||||
@@ -249,11 +248,7 @@ export class EntityManager<TBD extends object = DefaultDB> {
|
||||
}
|
||||
|
||||
schema() {
|
||||
if (!this._schema) {
|
||||
this._schema = new SchemaManager(this);
|
||||
}
|
||||
|
||||
return this._schema;
|
||||
return new SchemaManager(this);
|
||||
}
|
||||
|
||||
// @todo: centralize and add tests
|
||||
|
||||
Reference in New Issue
Block a user