Skip to content

Commit bef04e6

Browse files
bcrypt-nodejs -> bcrypt 변경
1 parent 1a73898 commit bef04e6

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Diff for: src/models/User.ts

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import bcrypt from 'bcrypt-nodejs';
1+
import bcrypt from 'bcrypt';
22
import { Document, Schema, Error, model } from 'mongoose';
33

44
export type UserDocument = Document & {
@@ -41,9 +41,7 @@ const userSchema = new Schema({
4141
}
4242
}, { timestamps: true });
4343

44-
/**
45-
* Password hash middleware.
46-
*/
44+
// 비밀번호 암호화
4745
userSchema.pre('save', function save(next) {
4846
const user = this as UserDocument;
4947
if (!user.isModified('password')) { return next(); }

0 commit comments

Comments
 (0)