diff --git a/static/app/components/devtoolbar/hooks/useCurrentTransactionName.tsx b/static/app/components/devtoolbar/hooks/useCurrentTransactionName.tsx index 47131b7d220cf3..4e0cae30767bf8 100644 --- a/static/app/components/devtoolbar/hooks/useCurrentTransactionName.tsx +++ b/static/app/components/devtoolbar/hooks/useCurrentTransactionName.tsx @@ -81,7 +81,7 @@ export function toSearchTerm(transaction) { // ([{]([^\/]*)[}]) matches {param} used by ASP.NET Core, Laravel, Symfony // ([<]([^\/]*)[>]) matches used by Flask, Django const parameterizedRegex = - / ([\/]) (([:]([^\/]*)) | ([\[]([^\/]*)[\]]) | ([{]([^\/]*)[}]) | ([<]([^\/]*)[>])) /g; + /([\/])(([:]([^\/]*))|([\[]([^\/]*)[\]])|([{]([^\/]*)[}])|([<]([^\/]*)[>]))/g; modifiedTransaction = modifiedTransaction.replaceAll(parameterizedRegex, '/*'); // transaction name could contain the resolved URL instead of the route pattern (ie actual id instead of :id)