diff --git a/mcp_servers/passenger/server.py b/mcp_servers/passenger/server.py index 908d44b..57ea9a2 100644 --- a/mcp_servers/passenger/server.py +++ b/mcp_servers/passenger/server.py @@ -67,9 +67,9 @@ def _template_notification(context: dict) -> str: "", ] - if weather_summary: - lines.append(f"Your flight is delayed due to {weather_summary}.") - elif delay_cause: + if crew_notes_summary: + lines.append(crew_notes_summary) + if delay_cause: cause_text = { "WEATHER": "weather conditions along your route", "MAINTENANCE": "a routine maintenance check on your aircraft", @@ -77,10 +77,10 @@ def _template_notification(context: dict) -> str: "ATC": "air traffic control restrictions", "LATE_AIRCRAFT": "the late arrival of your inbound aircraft", }.get(delay_cause, f"{delay_cause.lower()}") - lines.append(f"Your flight is delayed due to {cause_text}.") - - if crew_notes_summary: - lines.append(crew_notes_summary) + if not crew_notes_summary: + lines.append(f"Your flight is delayed due to {cause_text}.") + if weather_summary: + lines.append(f"Current conditions: {weather_summary}.") if gate: lines.append(f"\nGate {gate} — no gate change expected.")