]> cat aescling's git repositories - mastodon.git/commitdiff
[Glitch] Fix “Filter this post” potentially listing deleted filters
authorClaire <claire.github-309c@sitedethib.com>
Thu, 25 Aug 2022 15:36:35 +0000 (17:36 +0200)
committeraescling <aescling+gitlab@cat.family>
Mon, 5 Sep 2022 04:28:02 +0000 (00:28 -0400)
Port 2cae5f5b8d4d0702fe9835a0ce2782f238755d0c to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
app/javascript/flavours/glitch/reducers/filters.js

index cc1d3349c59a928017d65c4e5253e34e64cf436d..f4f97cd3a8a8cbb2bc8711c7f19349cb90686536 100644 (file)
@@ -35,7 +35,7 @@ export default function filters(state = ImmutableMap(), action) {
   case FILTERS_CREATE_SUCCESS:
     return normalizeFilter(state, action.filter);
   case FILTERS_FETCH_SUCCESS:
-    //TODO: handle deleting obsolete filters
+    return normalizeFilters(ImmutableMap(), action.filters);
   case FILTERS_IMPORT:
     return normalizeFilters(state, action.filters);
   default: