Refactor: Rename user_stats to user_profile and restructure schema

- Rename user_stats table to user_profile
- Split full_name into first_name and last_name columns
- Remove message_count (focus on profile data only)
- Add is_bot flag to track bot accounts
- Create migration.sql with automatic data migration and schema conversion
- Update MIGRATION.md with rename and migration instructions
- Update all DatabaseManager methods to use new table structure
- Update profile change detection to use separated name fields
This commit is contained in:
2026-06-09 20:42:49 +02:00
parent 2af4603ba3
commit d63f72be95
3 changed files with 75 additions and 59 deletions
+1
View File
@@ -84,3 +84,4 @@
[2026-06-09 20:28:04] | CHAT_ID=-1001202289941 | TOPIC=761 | TYPE=PROFILE_CHANGE | USER=151261436 (tokelemma) | DETAILS=Profiländerung erkannt | Name: 'Toke. 🌻' → 'Toke 🌻'
[2026-06-09 20:28:04] | CHAT_ID=-1001202289941 | TOPIC=761 | TYPE=MESSAGE | USER=151261436 (tokelemma) | DETAILS=Nachricht gesendet: 'Und back...'
[2026-06-09 20:28:04] | CHAT_ID=-1001202289941 | TOPIC=761 | TYPE=MESSAGE | USER=151261436 (tokelemma) | DETAILS=Nachricht gesendet: 'Und back...'
[2026-06-09 20:41:48] | CHAT_ID=-1001202289941 | TOPIC=761 | TYPE=MESSAGE | USER=151261436 (tokelemma) | DETAILS=Nachricht gesendet: 'Blaaaahah...'