Refactor relationship type retrieval in character workers: Simplify the extraction of relationship types in CharacterCreationWorker, EventsWorker, and UserCharacterWorker by streamlining the use of and_then for better readability and maintainability.

This commit is contained in:
Torsten Schulz (local)
2026-01-23 10:48:15 +01:00
parent 0399333163
commit c8668c59eb
3 changed files with 3 additions and 8 deletions

View File

@@ -1797,8 +1797,7 @@ impl EventsWorker {
.and_then(|v| v.parse::<i32>().ok());
let relationship_type_tr = row
.get("relationship_type_tr")
.and_then(|v| v.as_str())
.map(|s| s.to_string());
.and_then(|v| v.as_str().map(|s| s.to_string()));
// Logging: Relationship wurde gelöscht
eprintln!(