From 339251a3718fd73b36cf9a6d2d94c7f26e73b725 Mon Sep 17 00:00:00 2001 From: Joffrey JAFFEUX Date: Mon, 10 Mar 2025 22:17:24 +0100 Subject: [PATCH] FIX: prevents double escaping of filters (#1179) --------- Co-authored-by: Keegan George --- .../discourse/components/admin-report-sentiment-analysis.gjs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/assets/javascripts/discourse/components/admin-report-sentiment-analysis.gjs b/assets/javascripts/discourse/components/admin-report-sentiment-analysis.gjs index 2354ec14..fb97c5cc 100644 --- a/assets/javascripts/discourse/components/admin-report-sentiment-analysis.gjs +++ b/assets/javascripts/discourse/components/admin-report-sentiment-analysis.gjs @@ -219,6 +219,7 @@ export default class AdminReportSentimentAnalysis extends Component { this.router.transitionTo(this.router.currentRoute.name, { queryParams: { ...currentQueryParams, + filters: JSON.parse(currentQueryParams.filters), // avoids a double escaping selectedChart: data.title, }, }); @@ -267,6 +268,7 @@ export default class AdminReportSentimentAnalysis extends Component { this.router.transitionTo(this.router.currentRoute.name, { queryParams: { ...currentQueryParams, + filters: JSON.parse(currentQueryParams.filters), // avoids a double escaping selectedChart: null, }, });