Skip to content

Commit

Permalink
db util code moved to schema file.
Browse files Browse the repository at this point in the history
  • Loading branch information
iamtouha committed Feb 20, 2024
1 parent 14a99fe commit e0086f6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
5 changes: 4 additions & 1 deletion src/server/db/schema.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { mysqlTableCreator } from "drizzle-orm/mysql-core";
import { DATABASE_PREFIX as prefix } from "@/lib/constants";
import {
boolean,
datetime,
Expand All @@ -8,7 +10,8 @@ import {
varchar,
} from "drizzle-orm/mysql-core";
import { relations } from "drizzle-orm";
import { mysqlTable } from "@/server/db/util";

export const mysqlTable = mysqlTableCreator((name) => `${prefix}_${name}`);

export const users = mysqlTable(
"users",
Expand Down
12 changes: 0 additions & 12 deletions src/server/db/util.ts

This file was deleted.

0 comments on commit e0086f6

Please sign in to comment.