From f21bffe8c2d6d58e15b416f93ed0edbe4078f38c Mon Sep 17 00:00:00 2001
From: zhaoqingang <zhaoqg0118@163.com>
Date: 星期二, 25 二月 2025 15:41:12 +0800
Subject: [PATCH] 优化

---
 app/models/user_model.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/app/models/user_model.py b/app/models/user_model.py
index b76cdc8..7c4917e 100644
--- a/app/models/user_model.py
+++ b/app/models/user_model.py
@@ -189,7 +189,7 @@
 
 
     def encrypted_password(self, password):
-        return cipher_suite.encrypt(password.encode("utf-8")).decode("utf-8")
+        return cipher_suite.encrypt(str(password).encode("utf-8")).decode("utf-8")
 
     def decrypted_password(self):
         return cipher_suite.decrypt(self.password).decode("utf-8")

--
Gitblit v1.8.0