about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2022-10-18 18:57:01 +0200
committerClaire <claire.github-309c@sitedethib.com>2022-10-28 19:24:02 +0200
commit2aa70c112a5381ad6c81597dbe2cb04e29532aa8 (patch)
treef1b10cab9ac054430ad559a824adcfcb90a3e9d2
parent39ec0e8398def877572c8a489ae32473f449a8b3 (diff)
[Glitch] Fix error while server rules are loading in report modal in web UI
Port 4c7b5fb6c1787438ef130d9aecd5d0a4d54d08a9 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
-rw-r--r--app/javascript/flavours/glitch/features/report/category.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/javascript/flavours/glitch/features/report/category.js b/app/javascript/flavours/glitch/features/report/category.js
index 43fb7a17c..88a6c1969 100644
--- a/app/javascript/flavours/glitch/features/report/category.js
+++ b/app/javascript/flavours/glitch/features/report/category.js
@@ -5,6 +5,7 @@ import { connect } from 'react-redux';
 import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
 import Button from 'flavours/glitch/components/button';
 import Option from './components/option';
+import { List as ImmutableList } from 'immutable';
 
 const messages = defineMessages({
   dislike: { id: 'report.reasons.dislike', defaultMessage: 'I don\'t like it' },
@@ -20,7 +21,7 @@ const messages = defineMessages({
 });
 
 const mapStateToProps = state => ({
-  rules: state.getIn(['server', 'rules']),
+  rules: state.getIn(['server', 'rules'], ImmutableList()),
 });
 
 export default @connect(mapStateToProps)