mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 13:59:16 +01:00
refactor: ♻️ Don't use Bun global
This commit is contained in:
parent
d55668d529
commit
25ea870f71
15 changed files with 32 additions and 19 deletions
|
|
@ -34,6 +34,7 @@ import {
|
|||
Users,
|
||||
} from "@versia/kit/tables";
|
||||
import { randomUUIDv7 } from "bun";
|
||||
import { password as bunPassword } from "bun";
|
||||
import chalk from "chalk";
|
||||
import {
|
||||
type InferInsertModel,
|
||||
|
|
@ -890,7 +891,7 @@ export class User extends BaseInterface<typeof Users, UserWithRelations> {
|
|||
password:
|
||||
data.skipPasswordHash || !data.password
|
||||
? data.password
|
||||
: await Bun.password.hash(data.password),
|
||||
: await bunPassword.hash(data.password),
|
||||
email: data.email,
|
||||
note: data.bio ?? "",
|
||||
avatarId: data.avatar?.id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue