feat: separate db models from server

This commit is contained in:
wancat committed 2023-10-14 15:34:46 +08:00
1 parent 784ae29ed0
commit 50bf514805
23 files changed
+90 -31

No files matched your search

+1 -1
View File
@@ -1,7 +1,7 @@
import jwt from 'jsonwebtoken'
import { User } from '@linux-odyssey/models'
import bcrypt from 'bcrypt'
import config from '../config.js'
import User from '../models/user.js'
export function hashPassword(password) {
return bcrypt.hash(password, 10)
+1 -1
View File
@@ -2,7 +2,7 @@ import fs from 'fs/promises'
import path from 'path'
import yaml from 'yaml'
import Quest from '../models/quest.js'
import { Quest } from '@linux-odyssey/models'
const questDirectory = path.join(process.cwd(), '..', 'quests')