File tree Expand file tree Collapse file tree 2 files changed +0
-9
lines changed
Expand file tree Collapse file tree 2 files changed +0
-9
lines changed Original file line number Diff line number Diff line change @@ -143,10 +143,6 @@ def dashboard():
143143 audit_logs = AuditLog .query .filter_by (user_id = current_user .id ).order_by (AuditLog .timestamp .desc ()).all ()
144144 if current_user .user_level == 'admin' :
145145
146- if not current_user .password_changed :
147- flash ('You need to change your password first to continue.' , 'warning' )
148- return render_template ('change_password.html' , settings = system_settings )
149-
150146 total_users = User .query .count () # Count total users
151147 active_sessions = len (session ) # This is a basic approach. You may want to track sessions differently.
152148
Original file line number Diff line number Diff line change @@ -40,11 +40,6 @@ def login():
4040 login_user (user )
4141 log_action (user .id , user .username , 'Login' , f'User { user .username } logged in.' )
4242
43- # Check if the admin needs to change their password
44- if user .user_level == 'admin' and not user .password_changed :
45- flash ('You need to change your password first to continue.' , 'warning' )
46- return redirect (url_for ('auth.change_password' ))
47-
4843 flash (f'Login successful as { user .username } ' , 'success' )
4944 return redirect (url_for ('admin.dashboard' ))
5045 else :
You can’t perform that action at this time.
0 commit comments