From 857fc564ee2a025d2ea91e8d7b74224bf6641aaa Mon Sep 17 00:00:00 2001 From: AlexRV12 <71396855+AlexRV12@users.noreply.github.com> Date: Thu, 24 Sep 2026 17:27:23 +0200 Subject: [PATCH] feat: record which destination a variable expiration handler uses handler_configured now counts slack, teams, custom or cleared instead of set or cleared, so usage shows whether the built-in destinations are picked. Co-Authored-By: Claude Opus 5.5 (1M context) --- backend/windmill-api-workspaces/src/workspaces.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/backend/windmill-api-workspaces/src/workspaces.rs b/backend/windmill-api-workspaces/src/workspaces.rs index ab78fa16a0..e8bca01c81 100644 --- a/backend/windmill-api-workspaces/src/workspaces.rs +++ b/backend/windmill-api-workspaces/src/workspaces.rs @@ -5831,7 +5831,13 @@ async fn edit_variable_expiration_handler( windmill_common::feature_usage::log_feature_usage( "variable_expiration", "handler_configured", - if es.path.is_some() { "set" } else { "cleared" }, + // The built-ins are matched on the hub slug the frontend picks them by, not the hub id. + match es.path.as_deref() { + None => "cleared", + Some(p) if p.ends_with("/variable-expiration-handler-slack") => "slack", + Some(p) if p.ends_with("/variable-expiration-handler-teams") => "teams", + Some(_) => "custom", + }, ); Ok(format!(