Major version update. Major bugfixes. Security vulnerabilites fixed

This commit is contained in:
2026-10-14 03:02:07 +01:00
parent 4e47bd8ce0
commit 7c095f6f16
112 changed files with 2479 additions and 1219 deletions
+13
View File
@@ -0,0 +1,13 @@
import type { BUN_SQLITE_DatabaseSchemaType, CreateDBSchemaParams } from "../../types";
/**
* Topologically order tables so referenced (parent) tables come before the
* tables that reference them. Declaration order is kept wherever the FK
* graph allows it.
*
* - Self references (e.g. `comments.parent_comment_id`) are ignored.
* - References to tables outside the schema are ignored.
* - Cycles do not throw: a table already on the current path is skipped,
* so every table is still emitted exactly once. Foreign keys are not
* enforced during the sync, so cycles are safe.
*/
export default function orderDBSchema({ db_schema, }: Pick<CreateDBSchemaParams, "db_schema">): BUN_SQLITE_DatabaseSchemaType;