Browse Source

[FIX] username get

Gogs 7 năm trước cách đây
mục cha
commit
6f7cfa8558
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      api/utils/jwt_token.py

+ 2 - 2
api/utils/jwt_token.py

@@ -69,12 +69,12 @@ def get_user(token):
 '''
 def get_username(token):
     user = get_user(token)
-
+    
     # Check if exists user
     if not user:
         return user
 
-    return user.name
+    return user.username
 
 '''
 '''