From e1be281e3d2c1bcb46327ff8452b0860382649b2 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 6 Feb 2024 10:35:36 +0100 Subject: [PATCH] Fix report reason selector in moderation interface not unselecting rules when changing category (#29026) --- .../mastodon/components/admin/ReportReasonSelector.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/mastodon/components/admin/ReportReasonSelector.jsx b/app/javascript/mastodon/components/admin/ReportReasonSelector.jsx index ecce92b309..90f4334a6e 100644 --- a/app/javascript/mastodon/components/admin/ReportReasonSelector.jsx +++ b/app/javascript/mastodon/components/admin/ReportReasonSelector.jsx @@ -124,7 +124,7 @@ class ReportReasonSelector extends PureComponent { api().put(`/api/v1/admin/reports/${id}`, { category, - rule_ids, + rule_ids: category === 'violation' ? rule_ids : [], }).catch(err => { console.error(err); });