🎉 Refactored backend structure: Removed unused files including app_cleaned.py, admin_api.py, admin.py, user.py, and others. Updated settings.local.json to include additional Bash commands. Enhanced admin templates for better navigation and functionality. Improved logging and error handling across various modules.
This commit is contained in:
29
backend/utils/fix_indentation.py
Normal file
29
backend/utils/fix_indentation.py
Normal file
@ -0,0 +1,29 @@
|
||||
#!/usr/bin/env python3.11
|
||||
"""
|
||||
Skript zur Behebung von Einrückungsproblemen in user_management.py
|
||||
"""
|
||||
|
||||
def fix_indentation():
|
||||
file_path = 'blueprints/user_management.py'
|
||||
|
||||
with open(file_path, 'r') as f:
|
||||
content = f.read()
|
||||
|
||||
lines = content.split('\n')
|
||||
fixed_lines = []
|
||||
|
||||
for line in lines:
|
||||
# Behebe die falsche Einrückung nach 'with get_cached_session() as session:'
|
||||
if line.startswith(' ') and not line.strip().startswith('#'):
|
||||
# 7 Leerzeichen entfernen (von 15 auf 8)
|
||||
fixed_lines.append(' ' + line[15:])
|
||||
else:
|
||||
fixed_lines.append(line)
|
||||
|
||||
with open(file_path, 'w') as f:
|
||||
f.write('\n'.join(fixed_lines))
|
||||
|
||||
print('✅ Einrückung behoben')
|
||||
|
||||
if __name__ == "__main__":
|
||||
fix_indentation()
|
Reference in New Issue
Block a user