Development
This commit is contained in:
parent
5b1f905ed0
commit
44261e5b5c
6 changed files with 87 additions and 33 deletions
|
|
@ -1,6 +1,7 @@
|
|||
from pathlib import Path
|
||||
from flask import Blueprint, request, session, redirect, flash
|
||||
import os, re, secrets, sqlite3, time
|
||||
import settings
|
||||
from datetime import datetime, timezone
|
||||
import auth
|
||||
import config_utils
|
||||
|
|
@ -215,7 +216,7 @@ def accounts_delete():
|
|||
target = accounts[row_index]
|
||||
target_email = target.get('email_address', '').lower()
|
||||
current_email = session.get('email_address', '').lower()
|
||||
initial_email = os.environ.get('INITIAL_MANAGER_EMAIL', '').strip().lower()
|
||||
initial_email = settings.get_initial_manager_email()
|
||||
|
||||
if target_email == current_email and target_email != initial_email:
|
||||
flash('You cannot remove your own account.', 'error')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue